about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/compilers/llvm/git/openmp
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/compilers/llvm/git/openmp')
-rw-r--r--nixpkgs/pkgs/development/compilers/llvm/git/openmp/default.nix3
-rw-r--r--nixpkgs/pkgs/development/compilers/llvm/git/openmp/fix-find-tool.patch11
-rw-r--r--nixpkgs/pkgs/development/compilers/llvm/git/openmp/run-lit-directly.patch12
3 files changed, 8 insertions, 18 deletions
diff --git a/nixpkgs/pkgs/development/compilers/llvm/git/openmp/default.nix b/nixpkgs/pkgs/development/compilers/llvm/git/openmp/default.nix
index 52aeb4bd9800..d51335436ad2 100644
--- a/nixpkgs/pkgs/development/compilers/llvm/git/openmp/default.nix
+++ b/nixpkgs/pkgs/development/compilers/llvm/git/openmp/default.nix
@@ -11,6 +11,7 @@
 , clang-unwrapped
 , perl
 , pkg-config
+, xcbuild
 , version
 }:
 
@@ -39,6 +40,8 @@ stdenv.mkDerivation rec {
     (if stdenv.buildPlatform == stdenv.hostPlatform then llvm else targetLlvm)
   ];
 
+  nativeCheckInputs = lib.optional stdenv.hostPlatform.isDarwin xcbuild.xcrun;
+
   # Unsup:Pass:XFail:Fail
   # 26:267:16:8
   doCheck = false;
diff --git a/nixpkgs/pkgs/development/compilers/llvm/git/openmp/fix-find-tool.patch b/nixpkgs/pkgs/development/compilers/llvm/git/openmp/fix-find-tool.patch
index 103b054ed176..b7f51196f7ba 100644
--- a/nixpkgs/pkgs/development/compilers/llvm/git/openmp/fix-find-tool.patch
+++ b/nixpkgs/pkgs/development/compilers/llvm/git/openmp/fix-find-tool.patch
@@ -1,5 +1,5 @@
 diff --git a/libomptarget/DeviceRTL/CMakeLists.txt b/libomptarget/DeviceRTL/CMakeLists.txt
-index ce66214822a2..6ab7b33c95da 100644
+index 630947abec7e..9f032dc7bd3f 100644
 --- a/libomptarget/DeviceRTL/CMakeLists.txt
 +++ b/libomptarget/DeviceRTL/CMakeLists.txt
 @@ -27,10 +27,10 @@ endif()
@@ -8,11 +8,10 @@ index ce66214822a2..6ab7b33c95da 100644
    # A standalone or LLVM_ENABLE_RUNTIMES=openmp build takes this route
 -  find_program(CLANG_TOOL clang PATHS ${LLVM_TOOLS_BINARY_DIR} NO_DEFAULT_PATH)
 +  find_program(CLANG_TOOL clang PATHS ${LLVM_TOOLS_BINARY_DIR})
-   find_program(LINK_TOOL llvm-link PATHS ${LLVM_TOOLS_BINARY_DIR}
--    NO_DEFAULT_PATH)
+   find_program(PACKAGER_TOOL clang-offload-packager PATHS ${LLVM_TOOLS_BINARY_DIR} NO_DEFAULT_PATH)
+   find_program(LINK_TOOL llvm-link PATHS ${LLVM_TOOLS_BINARY_DIR} NO_DEFAULT_PATH)
 -  find_program(OPT_TOOL opt PATHS ${LLVM_TOOLS_BINARY_DIR} NO_DEFAULT_PATH)
-+    )
 +  find_program(OPT_TOOL opt PATHS ${LLVM_TOOLS_BINARY_DIR})
-   if ((NOT CLANG_TOOL) OR (NOT LINK_TOOL) OR (NOT OPT_TOOL))
-     libomptarget_say("Not building DeviceRTL. Missing clang: ${CLANG_TOOL}, llvm-link: ${LINK_TOOL} or opt: ${OPT_TOOL}")
+   if ((NOT CLANG_TOOL) OR (NOT LINK_TOOL) OR (NOT OPT_TOOL) OR (NOT PACKAGER_TOOL))
+     libomptarget_say("Not building DeviceRTL. Missing clang: ${CLANG_TOOL}, llvm-link: ${LINK_TOOL}, opt: ${OPT_TOOL}, or clang-offload-packager: ${PACKAGER_TOOL}")
      return()
diff --git a/nixpkgs/pkgs/development/compilers/llvm/git/openmp/run-lit-directly.patch b/nixpkgs/pkgs/development/compilers/llvm/git/openmp/run-lit-directly.patch
index 1e952fdc36a8..e69de29bb2d1 100644
--- a/nixpkgs/pkgs/development/compilers/llvm/git/openmp/run-lit-directly.patch
+++ b/nixpkgs/pkgs/development/compilers/llvm/git/openmp/run-lit-directly.patch
@@ -1,12 +0,0 @@
-diff --git a/cmake/OpenMPTesting.cmake b/cmake/OpenMPTesting.cmake
---- a/cmake/OpenMPTesting.cmake
-+++ b/cmake/OpenMPTesting.cmake
-@@ -185,7 +185,7 @@ function(add_openmp_testsuite target comment)
-   if (${OPENMP_STANDALONE_BUILD})
-     set(LIT_ARGS ${OPENMP_LIT_ARGS} ${ARG_ARGS})
-     add_custom_target(${target}
--      COMMAND ${PYTHON_EXECUTABLE} ${OPENMP_LLVM_LIT_EXECUTABLE} ${LIT_ARGS} ${ARG_UNPARSED_ARGUMENTS}
-+      COMMAND ${OPENMP_LLVM_LIT_EXECUTABLE} ${LIT_ARGS} ${ARG_UNPARSED_ARGUMENTS}
-       COMMENT ${comment}
-       DEPENDS ${ARG_DEPENDS}
-       USES_TERMINAL