summaryrefslogtreecommitdiff
path: root/gnu/packages
diff options
context:
space:
mode:
authorDavid Elsing <david.elsing@posteo.net>2026-02-03 21:33:21 +0100
committerLudovic Courtès <ludo@gnu.org>2026-02-10 23:46:31 +0100
commit913ff87b70356378bd8f2d7be0bfc25fbdd671b8 (patch)
tree28c71298e91f15459c7a9df8cead68522e6f9083 /gnu/packages
parent7d09e6f8815b6b4c1b2157ef9024026e85c65131 (diff)
gnu: make-llvm-rocm: Do not use --disable-new-dtags by default.
* gnu/packages/patches/clang-rocm-default-new-dtags.patch: New patch. * gnu/local.mk (dist_patch_DATA): Register it. * gnu/packages/llvm.scm (make-llvm-rocm)[source]: Add the patch. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Diffstat (limited to 'gnu/packages')
-rw-r--r--gnu/packages/llvm.scm4
-rw-r--r--gnu/packages/patches/clang-rocm-default-new-dtags.patch23
2 files changed, 26 insertions, 1 deletions
diff --git a/gnu/packages/llvm.scm b/gnu/packages/llvm.scm
index 3e87e5df748..3f08d073bb2 100644
--- a/gnu/packages/llvm.scm
+++ b/gnu/packages/llvm.scm
@@ -1403,7 +1403,9 @@ Library.")
;; is necessary.
(patches
(map search-patch
- (assoc-ref %llvm-patches (package-version llvm-base))))))
+ (cons
+ "clang-rocm-default-new-dtags.patch"
+ (assoc-ref %llvm-patches (package-version llvm-base)))))))
(arguments
(substitute-keyword-arguments (package-arguments llvm-base)
((#:configure-flags flags)
diff --git a/gnu/packages/patches/clang-rocm-default-new-dtags.patch b/gnu/packages/patches/clang-rocm-default-new-dtags.patch
new file mode 100644
index 00000000000..ce30d2513b2
--- /dev/null
+++ b/gnu/packages/patches/clang-rocm-default-new-dtags.patch
@@ -0,0 +1,23 @@
+Revert to the behavior that if no flag is specified, the LLVM default is
+used. Otherwise, the 'validate-runpath phase in Guix fails, as it looks at
+RUNPATH, not RPATH.
+
+The lines removed by this patch were introduced in
+https://github.com/ROCm/llvm-project/commit/eab679eba1ebe61b2cda99b27ad3f122a9caa14b
+
+diff --git a/clang/lib/Driver/ToolChains/CommonArgs.cpp b/clang/lib/Driver/ToolChains/CommonArgs.cpp
+index 4ce53b29e326..379b0507180e 100644
+--- a/clang/lib/Driver/ToolChains/CommonArgs.cpp
++++ b/clang/lib/Driver/ToolChains/CommonArgs.cpp
+@@ -1313,11 +1313,6 @@ void tools::addOpenMPRuntimeSpecificRPath(const ToolChain &TC,
+ // lib-debug/lib-perf
+ if (LibSuffix != "lib")
+ addRPathCmdArg(Args, CmdArgs, DefaultLibPath.c_str());
+-
+- if (llvm::find_if(CmdArgs, [](StringRef str) {
+- return !str.compare("--enable-new-dtags");
+- }) == CmdArgs.end())
+- CmdArgs.push_back("--disable-new-dtags");
+ }
+ }
+