Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 832173

Summary: dev-util/roctracer-4.3.0 : does not install *_ostream_ops.h headers
Product: Gentoo Linux Reporter: Jason Zaman <perfinion>
Component: Current packagesAssignee: Gentoo Science Related Packages <sci>
Status: RESOLVED FIXED    
Severity: normal CC: candrews, gentoo
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
See Also: https://bugs.gentoo.org/show_bug.cgi?id=779658
Whiteboard:
Package list:
Runtime testing required: ---

Description Jason Zaman gentoo-dev 2022-01-27 21:47:32 UTC
roctracer does not install the following header files:

/usr/include/roctracer/hip_ostream_ops.h
/usr/include/roctracer/hsa_ostream_ops.h
/usr/include/roctracer/hsa_prof_str.h
/usr/include/roctracer/kfd_ostream_ops.h
/usr/include/roctracer/kfd_prof_str.h

The culprit is the sed line which removes the PROJECT_BINARY_DIR install lines. It looks like that line is supposed to remove the so-link lines but also ends up removing this one:
install ( FILES ${PROJECT_BINARY_DIR}/inc/${header} DESTINATION include/${DEST_NAME}/${header_subdir} )

https://bugs.gentoo.org/779658 came up in a search but appears to be a separate problem. that one is an issue during compile time which seems fixed in 4.3.0, the only remaining problem is just that the header needs to be installed


This patch fixes the issue for me. With it I have been able to successfully compile TensorFlow against the gentoo rocm packages (coming soon!)

diff --git a/dev-util/roctracer/roctracer-4.3.0.ebuild b/dev-util/roctracer/roctracer-4.3.0.ebuild
index 35092c81a55..83793fcf51b 100644
--- a/dev-util/roctracer/roctracer-4.3.0.ebuild
+++ b/dev-util/roctracer/roctracer-4.3.0.ebuild
@@ -47,7 +47,7 @@ src_prepare() {
        sed -e "/LIBRARY DESTINATION/s,lib,$(get_libdir)," \
                -e "/add_subdirectory ( \${TEST_DIR} \${PROJECT_BINARY_DIR}/d" \
                -e "/DESTINATION/s,\${DEST_NAME}/include,include/roctracer," \
-               -e "/install ( FILES \${PROJECT_BINARY_DIR}/d" \
+               -e "/install ( FILES \${PROJECT_BINARY_DIR}\/so/d" \
                -e "/DESTINATION/s,\${DEST_NAME}/lib64,$(get_libdir)/roctracer,g" \
                -i CMakeLists.txt || die
Comment 1 Benda Xu gentoo-dev 2022-01-29 05:46:40 UTC
Hi Jason,

(In reply to Jason Zaman from comment #0)
> roctracer does not install the following header files:
> 
> /usr/include/roctracer/hip_ostream_ops.h
> /usr/include/roctracer/hsa_ostream_ops.h
> /usr/include/roctracer/hsa_prof_str.h
> /usr/include/roctracer/kfd_ostream_ops.h
> /usr/include/roctracer/kfd_prof_str.h
> 
> The culprit is the sed line which removes the PROJECT_BINARY_DIR install
> lines. It looks like that line is supposed to remove the so-link lines but
> also ends up removing this one:
> install ( FILES ${PROJECT_BINARY_DIR}/inc/${header} DESTINATION
> include/${DEST_NAME}/${header_subdir} )
> 
> https://bugs.gentoo.org/779658 came up in a search but appears to be a
> separate problem. that one is an issue during compile time which seems fixed
> in 4.3.0, the only remaining problem is just that the header needs to be
> installed
> 
> 
> This patch fixes the issue for me. With it I have been able to successfully
> compile TensorFlow against the gentoo rocm packages (coming soon!)
> 
> diff --git a/dev-util/roctracer/roctracer-4.3.0.ebuild
> b/dev-util/roctracer/roctracer-4.3.0.ebuild
> index 35092c81a55..83793fcf51b 100644
> --- a/dev-util/roctracer/roctracer-4.3.0.ebuild
> +++ b/dev-util/roctracer/roctracer-4.3.0.ebuild
> @@ -47,7 +47,7 @@ src_prepare() {
>         sed -e "/LIBRARY DESTINATION/s,lib,$(get_libdir)," \
>                 -e "/add_subdirectory ( \${TEST_DIR}
> \${PROJECT_BINARY_DIR}/d" \
>                 -e "/DESTINATION/s,\${DEST_NAME}/include,include/roctracer,"
> \
> -               -e "/install ( FILES \${PROJECT_BINARY_DIR}/d" \
> +               -e "/install ( FILES \${PROJECT_BINARY_DIR}\/so/d" \
>                 -e
> "/DESTINATION/s,\${DEST_NAME}/lib64,$(get_libdir)/roctracer,g" \
>                 -i CMakeLists.txt || die

You are right. Thanks for pointing this out.

Please go ahead to push your ebuild update with a revision bump.

Cheers,
Benda
Comment 2 Jason Zaman gentoo-dev 2022-01-30 07:58:14 UTC
(In reply to Benda Xu from comment #1)
> You are right. Thanks for pointing this out.
> 
> Please go ahead to push your ebuild update with a revision bump.
> 
> Cheers,
> Benda

Thanks! will do :)

-- Jason
Comment 3 Larry the Git Cow gentoo-dev 2022-01-30 08:07:57 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8445d3adc3d4431e7fa99ce8be29dd61530e9a0a

commit 8445d3adc3d4431e7fa99ce8be29dd61530e9a0a
Author:     Jason Zaman <perfinion@gentoo.org>
AuthorDate: 2022-01-30 08:06:03 +0000
Commit:     Jason Zaman <perfinion@gentoo.org>
CommitDate: 2022-01-30 08:07:28 +0000

    dev-util/roctracer: Install _ostream_ops headers
    
    Closes: https://bugs.gentoo.org/832173
    Package-Manager: Portage-3.0.30, Repoman-3.0.3
    Signed-off-by: Jason Zaman <perfinion@gentoo.org>

 .../roctracer/{roctracer-4.3.0.ebuild => roctracer-4.3.0-r1.ebuild}   | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)