Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 936099 - dev-libs/rocm-device-libs-6.1.1 fails to build
Summary: dev-libs/rocm-device-libs-6.1.1 fails to build
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Craig Andrews
URL:
Whiteboard:
Keywords: PullRequest
Depends on:
Blocks:
 
Reported: 2024-07-15 08:55 UTC by Stefano Crocco
Modified: 2024-09-09 18:20 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Build log (build.log,6.13 KB, text/x-log)
2024-07-15 08:55 UTC, Stefano Crocco
Details
Emerge --info (emerge_info,7.90 KB, text/plain)
2024-07-15 08:55 UTC, Stefano Crocco
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stefano Crocco 2024-07-15 08:55:08 UTC
Created attachment 897654 [details]
Build log

When I try to build dev-libs/rocm-device-libs-6.1.1, I get an error with the following message (full build log attached):
CMake Error at /usr/share/cmake/Modules/CMakeTestCCompiler.cmake:67 (message):
  The C compiler

    "/usr/lib/llvm/18/bin/clang"

  is not able to compile a simple test program.

This has been happening for about a couple of weeks. What's strange is that on another system, it builds correctly. Reinstalling llvm, clang and cmake didn't solve the issue.
Comment 1 Stefano Crocco 2024-07-15 08:55:29 UTC
Created attachment 897655 [details]
Emerge --info
Comment 2 Sv. Lockal 2024-07-17 18:27:03 UTC
Note: similar issue was reported at https://www.reddit.com/r/Gentoo/comments/1e4rtuv/cant_emerge_package_clang_doesnt_support_gcc/ - there user had CXXFLAGS:

CXXFLAGS="-march=znver2 -O3 -flto=12 -ffat-lto-objects -fgraphite-identity -floop-nest-optimize -fipa-pta -fno-semantic-interposition -fdevirtualize-at-ltrans  -fuse-linker-plugin -pipe -frecord-gcc-switches'"

(note '-flto=12' - clang does not support this either).

Even though the workaround is well-known and described in https://wiki.gentoo.org/wiki/Clang#Configuration (one of many places), I think we can do better by cleaning flags with:

	if ! tc-is-clang ; then
		strip-flags
		filter-lto
	fi

This will affect packages (approximately):

dev-libs/rocm-device-libs
dev-libs/rccl
dev-util/Tensile
sci-libs/composable-kernel
sci-libs/hipBLAS
sci-libs/hipBLASLt
sci-libs/hipCUB
sci-libs/hipFFT
sci-libs/hipRAND
sci-libs/hipSOLVER
sci-libs/miopen
sci-libs/rocBLAS
sci-libs/rocFFT
sci-libs/rocPRIM
sci-libs/rocRAND
sci-libs/rocSOLVER
sci-libs/rocSPARSE
sci-libs/rocThrust
sci-libs/rocWMMA

I'll do the patch.
Comment 3 Larry the Git Cow gentoo-dev 2024-09-09 18:20:37 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=31a45f02c1df2f828972c42210b298786bf122e6

commit 31a45f02c1df2f828972c42210b298786bf122e6
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 16:23:32 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:11 +0000

    dev-libs/rocm-device-libs: strip unsupported flags for potentially switched compiler
    
    Closes: https://bugs.gentoo.org/936099
    Closes: https://bugs.gentoo.org/937276
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 dev-libs/rocm-device-libs/rocm-device-libs-6.1.1.ebuild | 13 +++++++++----
 dev-libs/rocm-device-libs/rocm-device-libs-6.1.2.ebuild | 13 +++++++++----
 2 files changed, 18 insertions(+), 8 deletions(-)

Additionally, it has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=58ee8b5d08feb2cf8e7257f4033a19ba1cd2312e

commit 58ee8b5d08feb2cf8e7257f4033a19ba1cd2312e
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:54:22 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:20 +0000

    dev-util/roctracer: strip unsupported flags for potentially switched compiler
    
    Also fix libc++ in hipcc (clang-18) has no <experimental/filesystem>.
    
    Also remove unused cmake flag.
    
    Bug: https://bugs.gentoo.org/936099
    Closes: https://bugs.gentoo.org/854111
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

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

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=717c026f41e03df90881c5cca1c1c8390e71b8b5

commit 717c026f41e03df90881c5cca1c1c8390e71b8b5
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:43:30 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:20 +0000

    sci-libs/rocWMMA: strip unsupported flags for potentially switched compiler
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 sci-libs/rocWMMA/rocWMMA-6.1.1.ebuild | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

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

commit a8ebfeb02eb7b1bc84d2108a3a933d998604c141
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:41:48 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:19 +0000

    sci-libs/rocThrust: strip unsupported flags for potentially switched compiler
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 sci-libs/rocThrust/rocThrust-6.1.1.ebuild | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

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

commit b52cb8aabff7fbbbc7e640903dea2a5c558b4304
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:38:56 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:19 +0000

    sci-libs/rocSPARSE: strip unsupported flags for potentially switched compiler
    
    Also remove addpredict in src_configure (not needed after rocm_use_hipcc)
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 sci-libs/rocSPARSE/rocSPARSE-6.1.1.ebuild | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1d606e6db2981df0541da76f554142dab10058df

commit 1d606e6db2981df0541da76f554142dab10058df
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:37:23 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:18 +0000

    sci-libs/rocSOLVER: strip unsupported flags for potentially switched compiler
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 sci-libs/rocSOLVER/rocSOLVER-6.1.1.ebuild | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=62bb5fbe5f59d08e4079caed6229ca9e95c20000

commit 62bb5fbe5f59d08e4079caed6229ca9e95c20000
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:35:57 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:18 +0000

    sci-libs/rocRAND: strip unsupported flags for potentially switched compiler
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 sci-libs/rocRAND/rocRAND-6.1.1.ebuild | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

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

commit ae00b35d6bf3c102470f0d79ff470093b3e81421
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:34:40 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:17 +0000

    sci-libs/rocPRIM: strip unsupported flags for potentially switched compiler
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 sci-libs/rocPRIM/rocPRIM-6.1.1.ebuild | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=49badac556ce194ade8e48f893f205b967c67fcd

commit 49badac556ce194ade8e48f893f205b967c67fcd
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:33:11 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:17 +0000

    sci-libs/rocFFT: strip unsupported flags for potentially switched compiler
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 sci-libs/rocFFT/rocFFT-6.1.1.ebuild | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

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

commit f326e368b68e3fb544bd8acfef09f149366c0c89
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:31:24 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:16 +0000

    sci-libs/rocBLAS: strip unsupported flags for potentially switched compiler
    
    Also remove addpredict in src_configure (not needed after rocm_use_hipcc)
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 sci-libs/rocBLAS/rocBLAS-6.1.1.ebuild | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=536c5edf1c72611e018e0efbb913097d66db6206

commit 536c5edf1c72611e018e0efbb913097d66db6206
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:28:48 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:16 +0000

    sci-libs/miopen: strip unsupported flags for potentially switched compiler
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 sci-libs/miopen/miopen-6.1.1.ebuild | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5eef57ad9c2ee2dce41ebccc5e8a4f95731e26d6

commit 5eef57ad9c2ee2dce41ebccc5e8a4f95731e26d6
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:26:46 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:15 +0000

    sci-libs/hipSOLVER: strip unsupported flags for potentially switched compiler
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 sci-libs/hipSOLVER/hipSOLVER-6.1.1.ebuild | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=16f30d511ea0c7f9f641df92115c17f0cc008e31

commit 16f30d511ea0c7f9f641df92115c17f0cc008e31
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:22:34 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:14 +0000

    sci-libs/hipRAND: strip unsupported flags for potentially switched compiler
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 sci-libs/hipRAND/hipRAND-6.1.1.ebuild | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

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

commit d9cf465d946aad98b1e7a5efd4d2fc3db72b1be0
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:18:02 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:14 +0000

    sci-libs/hipCUB: strip unsupported flags for potentially switched compiler
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 sci-libs/hipCUB/hipCUB-6.1.1.ebuild | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9d5cf22dc4d217e975745cedf2726e2d76b96864

commit 9d5cf22dc4d217e975745cedf2726e2d76b96864
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 17:14:32 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:13 +0000

    sci-libs/hipBLASLt: strip unsupported flags for potentially switched compiler
    
    Additionally: fix compilation with libc++ and unresolved symbols
    
    Bug: https://bugs.gentoo.org/936099
    Closes: https://bugs.gentoo.org/935998
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 .../files/hipBLASLt-6.1.1-fix-libcxx.patch         | 57 ++++++++++++++++++++++
 .../hipBLASLt/files/hipBLASLt-6.1.1-no-arch.patch  |  5 +-
 ...ASLt-6.1.1.ebuild => hipBLASLt-6.1.1-r1.ebuild} |  5 +-
 3 files changed, 64 insertions(+), 3 deletions(-)

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=09c22f713957e25b9b530b318704421eaf2347a2

commit 09c22f713957e25b9b530b318704421eaf2347a2
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 16:59:43 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:13 +0000

    sci-libs/composable-kernel: strip unsupported flags for potentially switched compiler
    
    Additionally: fix compilation with libc++
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 .../composable-kernel-6.1.1.ebuild                 |  5 ++++-
 .../files/composable-kernel-6.1.1-fix-libcxx.patch | 25 ++++++++++++++++++++++
 2 files changed, 29 insertions(+), 1 deletion(-)

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1dc80dbbc4d5d8a3f46be05cac0772bf4cd2cf60

commit 1dc80dbbc4d5d8a3f46be05cac0772bf4cd2cf60
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 16:57:39 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:12 +0000

    dev-util/Tensile: strip unsupported flags for potentially switched compiler
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 dev-util/Tensile/Tensile-6.1.1.ebuild | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=04ceaab8ef6b1af51bfeb8cf2ab69c5828d636ae

commit 04ceaab8ef6b1af51bfeb8cf2ab69c5828d636ae
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 16:53:28 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:12 +0000

    dev-libs/rccl: strip unsupported flags for potentially switched compiler
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 dev-libs/rccl/rccl-6.1.1.ebuild | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

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

commit a9928b64eece2848421012645ffc101aade998fe
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-20 16:34:59 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:11 +0000

    sci-libs/hipFFT: strip unsupported flags for potentially switched compiler
    
    Also set compiler to hipcc (clang fails when libc++ is enabled instead of libstdc++)
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 sci-libs/hipFFT/hipFFT-6.1.1.ebuild | 4 ++++
 1 file changed, 4 insertions(+)

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

commit e2c865d8b5507755d6ad9c63e3b4b8ccbb5d6cd7
Author:     Sv. Lockal <lockalsash@gmail.com>
AuthorDate: 2024-07-30 23:14:55 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-09-09 18:15:10 +0000

    rocm.eclass: add rocm_use_hipcc function and update example accordingly
    
    Bug: https://bugs.gentoo.org/936099
    Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
    Signed-off-by: Sam James <sam@gentoo.org>

 eclass/rocm.eclass | 40 ++++++++++++++++++++++++++++++++++------
 1 file changed, 34 insertions(+), 6 deletions(-)