diff options
Diffstat (limited to 'pkgs/development/rocm-modules/6/llvm/stage-1/clang-unwrapped.nix')
-rw-r--r-- | pkgs/development/rocm-modules/6/llvm/stage-1/clang-unwrapped.nix | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/pkgs/development/rocm-modules/6/llvm/stage-1/clang-unwrapped.nix b/pkgs/development/rocm-modules/6/llvm/stage-1/clang-unwrapped.nix index 5a61732ffd2d4..0d982299ec6ee 100644 --- a/pkgs/development/rocm-modules/6/llvm/stage-1/clang-unwrapped.nix +++ b/pkgs/development/rocm-modules/6/llvm/stage-1/clang-unwrapped.nix @@ -2,13 +2,14 @@ , callPackage , rocmUpdateScript , llvm +, makeWrapper }: callPackage ../base.nix rec { inherit stdenv rocmUpdateScript; targetName = "clang-unwrapped"; targetDir = "clang"; - extraBuildInputs = [ llvm ]; + extraBuildInputs = [ llvm makeWrapper ]; extraCMakeFlags = [ "-DCLANG_INCLUDE_DOCS=ON" @@ -20,7 +21,7 @@ callPackage ../base.nix rec { ln -s ../cmake/Modules/FindLibEdit.cmake cmake/modules substituteInPlace CMakeLists.txt \ - --replace "include(CheckIncludeFile)" "include(CheckIncludeFile)''\nfind_package(LibEdit)" + --replace-fail "include(CheckIncludeFile)" "include(CheckIncludeFile)''\nfind_package(LibEdit)" # `No such file or directory: '/build/source/clang/tools/scan-build/bin/scan-build'` rm test/Analysis/scan-build/*.test @@ -41,6 +42,12 @@ callPackage ../base.nix rec { extraPostInstall = '' mv bin/clang-tblgen $out/bin + # add wrapper to compress embedded accelerator-specific code + # this makes the output of composable_kernel significantly smaller right now + # TODO: remove this once ROCm does it out of the box + mv $out/bin/clang-offload-bundler $out/bin/clang-offload-bundler-unwrapped + makeWrapper $out/bin/clang-offload-bundler-unwrapped $out/bin/clang-offload-bundler \ + --add-flags '-compress' ''; requiredSystemFeatures = [ "big-parallel" ]; |