diff options
Diffstat (limited to 'pkgs/development/compilers/llvm/git/openmp/gnu-install-dirs.patch')
-rw-r--r-- | pkgs/development/compilers/llvm/git/openmp/gnu-install-dirs.patch | 73 |
1 files changed, 3 insertions, 70 deletions
diff --git a/pkgs/development/compilers/llvm/git/openmp/gnu-install-dirs.patch b/pkgs/development/compilers/llvm/git/openmp/gnu-install-dirs.patch index 352a46923115..77a93208832a 100644 --- a/pkgs/development/compilers/llvm/git/openmp/gnu-install-dirs.patch +++ b/pkgs/development/compilers/llvm/git/openmp/gnu-install-dirs.patch @@ -1,17 +1,8 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt -index 7f11a05f5622..fb90f8f6a49b 100644 +index b6ddbe90516d..311ab1d50e7f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -8,6 +8,8 @@ if (OPENMP_STANDALONE_BUILD OR "${CMAKE_SOURCE_DIR}" STREQUAL "${CMAKE_CURRENT_S - set(OPENMP_STANDALONE_BUILD TRUE) - project(openmp C CXX) - -+ include(GNUInstallDirs) -+ - # CMAKE_BUILD_TYPE was not set, default to Release. - if (NOT CMAKE_BUILD_TYPE) - set(CMAKE_BUILD_TYPE Release) -@@ -19,7 +21,7 @@ if (OPENMP_STANDALONE_BUILD OR "${CMAKE_SOURCE_DIR}" STREQUAL "${CMAKE_CURRENT_S +@@ -29,7 +29,7 @@ if (OPENMP_STANDALONE_BUILD) set(OPENMP_LIBDIR_SUFFIX "" CACHE STRING "Suffix of lib installation directory, e.g. 64 => lib64") # Do not use OPENMP_LIBDIR_SUFFIX directly, use OPENMP_INSTALL_LIBDIR. @@ -20,7 +11,7 @@ index 7f11a05f5622..fb90f8f6a49b 100644 # Group test settings. set(OPENMP_TEST_C_COMPILER ${CMAKE_C_COMPILER} CACHE STRING -@@ -30,7 +32,7 @@ if (OPENMP_STANDALONE_BUILD OR "${CMAKE_SOURCE_DIR}" STREQUAL "${CMAKE_CURRENT_S +@@ -40,7 +40,7 @@ if (OPENMP_STANDALONE_BUILD) else() set(OPENMP_ENABLE_WERROR ${LLVM_ENABLE_WERROR}) # If building in tree, we honor the same install suffix LLVM uses. @@ -29,61 +20,3 @@ index 7f11a05f5622..fb90f8f6a49b 100644 if (NOT MSVC) set(OPENMP_TEST_C_COMPILER ${LLVM_RUNTIME_OUTPUT_INTDIR}/clang) -index 0e1ce2afd154..8b3810f83713 100644 ---- a/libomptarget/plugins/amdgpu/CMakeLists.txt -+++ b/libomptarget/plugins/amdgpu/CMakeLists.txt -@@ -80,7 +80,7 @@ add_library(omptarget.rtl.amdgpu SHARED - - # Install plugin under the lib destination folder. - # When we build for debug, OPENMP_LIBDIR_SUFFIX get set to -debug --install(TARGETS omptarget.rtl.amdgpu LIBRARY DESTINATION "lib${OPENMP_LIBDIR_SUFFIX}") -+install(TARGETS omptarget.rtl.amdgpu LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}${OPENMP_LIBDIR_SUFFIX}") - set_property(TARGET omptarget.rtl.amdgpu PROPERTY INSTALL_RPATH_USE_LINK_PATH ON) - - if(CMAKE_SYSTEM_NAME MATCHES "FreeBSD") -diff --git a/libomptarget/plugins/ve/CMakeLists.txt b/libomptarget/plugins/ve/CMakeLists.txt -index 16ce0891ca23..db30ee9c769f 100644 ---- a/libomptarget/plugins/ve/CMakeLists.txt -+++ b/libomptarget/plugins/ve/CMakeLists.txt -@@ -32,7 +32,7 @@ if(${LIBOMPTARGET_DEP_VEO_FOUND}) - - # Install plugin under the lib destination folder. - install(TARGETS "omptarget.rtl.${tmachine_libname}" -- LIBRARY DESTINATION lib${OPENMP_LIBDIR_SUFFIX}) -+ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}${OPENMP_LIBDIR_SUFFIX}) - - target_link_libraries( - "omptarget.rtl.${tmachine_libname}" -diff --git a/runtime/src/CMakeLists.txt b/runtime/src/CMakeLists.txt -index e4f4e6e1e73f..1164b3b22b0e 100644 ---- a/runtime/src/CMakeLists.txt -+++ b/runtime/src/CMakeLists.txt -@@ -346,13 +346,13 @@ add_dependencies(libomp-micro-tests libomp-test-deps) - # We want to install libomp in DESTDIR/CMAKE_INSTALL_PREFIX/lib - # We want to install headers in DESTDIR/CMAKE_INSTALL_PREFIX/include - if(${OPENMP_STANDALONE_BUILD}) -- set(LIBOMP_HEADERS_INSTALL_PATH include) -+ set(LIBOMP_HEADERS_INSTALL_PATH "${CMAKE_INSTALL_INCLUDEDIR}") - else() - string(REGEX MATCH "[0-9]+\\.[0-9]+(\\.[0-9]+)?" CLANG_VERSION ${PACKAGE_VERSION}) - set(LIBOMP_HEADERS_INSTALL_PATH "${OPENMP_INSTALL_LIBDIR}/clang/${CLANG_VERSION}/include") - endif() - if(WIN32) -- install(TARGETS omp RUNTIME DESTINATION bin) -+ install(TARGETS omp RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) - install(TARGETS ${LIBOMP_IMP_LIB_TARGET} ARCHIVE DESTINATION "${OPENMP_INSTALL_LIBDIR}") - # Create aliases (regular copies) of the library for backwards compatibility - set(LIBOMP_ALIASES "libiomp5md") -diff --git a/tools/multiplex/CMakeLists.txt b/tools/multiplex/CMakeLists.txt -index 64317c112176..4002784da736 100644 ---- a/tools/multiplex/CMakeLists.txt -+++ b/tools/multiplex/CMakeLists.txt -@@ -4,7 +4,7 @@ if(LIBOMP_OMPT_SUPPORT) - add_library(ompt-multiplex INTERFACE) - target_include_directories(ompt-multiplex INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}) - -- install(FILES ompt-multiplex.h DESTINATION include) -+ install(FILES ompt-multiplex.h DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) - - add_subdirectory(tests) - endif() |