summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHarmen Stoppels <harmenstoppels@gmail.com>2022-02-10 23:04:54 +0100
committerGitHub <noreply@github.com>2022-02-10 23:04:54 +0100
commit93e7efdc42aa2c562e1a33060afac7ed8e11d9bf (patch)
tree156f3cc5377f04a53ab0c56f6203408071b9d471
parent16d1746fc3075f73829307ab3f3b44e9e05d9db4 (diff)
downloadspack-93e7efdc42aa2c562e1a33060afac7ed8e11d9bf.tar.gz
spack-93e7efdc42aa2c562e1a33060afac7ed8e11d9bf.tar.bz2
spack-93e7efdc42aa2c562e1a33060afac7ed8e11d9bf.tar.xz
spack-93e7efdc42aa2c562e1a33060afac7ed8e11d9bf.zip
hsakmt-roct: dont look for libudev or compiler support libs (#28861)
-rw-r--r--var/spack/repos/builtin/packages/hsakmt-roct/0001-Remove-compiler-support-libraries-and-libudev-as-req.patch34
-rw-r--r--var/spack/repos/builtin/packages/hsakmt-roct/package.py4
2 files changed, 38 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/hsakmt-roct/0001-Remove-compiler-support-libraries-and-libudev-as-req.patch b/var/spack/repos/builtin/packages/hsakmt-roct/0001-Remove-compiler-support-libraries-and-libudev-as-req.patch
new file mode 100644
index 0000000000..b0a04e3e84
--- /dev/null
+++ b/var/spack/repos/builtin/packages/hsakmt-roct/0001-Remove-compiler-support-libraries-and-libudev-as-req.patch
@@ -0,0 +1,34 @@
+From 423bfb21eee3f75c5a116a88f7903a7dfb9ff89c Mon Sep 17 00:00:00 2001
+From: Harmen Stoppels <harmenstoppels@gmail.com>
+Date: Thu, 10 Feb 2022 13:50:55 +0100
+Subject: [PATCH] Remove compiler support libraries and libudev as required
+ dependencies
+
+---
+ CMakeLists.txt | 10 ----------
+ 1 file changed, 10 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 077ab51..0af642e 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -187,16 +187,6 @@ target_link_libraries ( ${HSAKMT_TARGET}
+ )
+
+ target_compile_options(${HSAKMT_TARGET} PRIVATE ${DRM_CFLAGS} ${HSAKMT_C_FLAGS})
+-if(NOT DISTRO_ID MATCHES "ubuntu")
+- find_library(LIBGCC NAMES libgcc_s.so.1 REQUIRED)
+- message(STATUS "LIBGCC:" ${LIBGCC})
+- target_link_libraries( ${HSAKMT_TARGET} PRIVATE ${LIBGCC} )
+-else()
+- find_library(UDEV NAMES libudev.so libudev.a REQUIRED)
+- message(STATUS "UDEV:" ${UDEV})
+- find_package(ZLIB REQUIRED)
+- target_link_libraries( ${HSAKMT_TARGET} PRIVATE ${ZLIB} ${UDEV} )
+-endif()
+
+ ## Define default paths and packages.
+ if( CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT )
+--
+2.25.1
+
diff --git a/var/spack/repos/builtin/packages/hsakmt-roct/package.py b/var/spack/repos/builtin/packages/hsakmt-roct/package.py
index 30a1c10d5a..cae33a1418 100644
--- a/var/spack/repos/builtin/packages/hsakmt-roct/package.py
+++ b/var/spack/repos/builtin/packages/hsakmt-roct/package.py
@@ -40,6 +40,10 @@ class HsakmtRoct(CMakePackage):
depends_on('numactl')
depends_on('libdrm', when='@4.5.0:')
+ # See https://github.com/RadeonOpenCompute/ROCT-Thunk-Interface/issues/72
+ # and https://github.com/spack/spack/issues/28398
+ patch('0001-Remove-compiler-support-libraries-and-libudev-as-req.patch', when='@4.5.0:')
+
@property
def install_targets(self):
if self.version == Version('3.5.0'):