File: fix-hiprtc-link.patch

package info (click to toggle)
rocfft 6.4.3-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 6,968 kB
  • sloc: cpp: 72,181; python: 6,506; sh: 387; xml: 204; makefile: 63
file content (29 lines) | stat: -rw-r--r-- 1,011 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
From: Cordell Bloor <cgmb@slerp.xyz>
Date: Tue, 23 May 2023 18:57:14 -0600
Subject: fix hiprtc link

The upstream build code linking hiprtc doesn't work with the Debian
package for hiprtc. The hip rtc library is correctly linked by
hip::host, so there's no need to handle it separately. That said, some
other packages for HIP (such as those provided by Spack), have patched
out the automatic linking of hiprtc in hip::host, so upstream will
probably want to find an alternative solution.

Forwarded: not-needed
---
 library/src/CMakeLists.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/library/src/CMakeLists.txt b/library/src/CMakeLists.txt
index 63c584b..c02f2fb 100644
--- a/library/src/CMakeLists.txt
+++ b/library/src/CMakeLists.txt
@@ -56,7 +56,7 @@ else()
   if( WIN32 )
     set( ROCFFT_RTC_LINK_LIBS "${HIP_PATH}/lib/hiprtc.lib" )
   else()
-    set( ROCFFT_RTC_LINK_LIBS -L${ROCM_PATH}/lib -lhiprtc -ldl )
+    set( ROCFFT_RTC_LINK_LIBS hip::host -ldl )
   endif()
 endif()