mirror of
https://github.com/wolfpld/tracy.git
synced 2026-06-08 08:33:48 +00:00
Make rocprof optional
This commit is contained in:
@@ -33,7 +33,7 @@ else()
|
||||
endif()
|
||||
|
||||
find_package(Threads REQUIRED)
|
||||
find_package(rocprofiler-sdk REQUIRED PATHS "/opt/rocm/lib/cmake")
|
||||
find_package(rocprofiler-sdk PATHS "/opt/rocm/lib/cmake")
|
||||
|
||||
set(TRACY_PUBLIC_DIR ${CMAKE_CURRENT_SOURCE_DIR}/public)
|
||||
|
||||
@@ -56,8 +56,11 @@ target_link_libraries(
|
||||
PUBLIC
|
||||
Threads::Threads
|
||||
${CMAKE_DL_LIBS}
|
||||
rocprofiler-sdk::rocprofiler-sdk
|
||||
)
|
||||
if(rocprofiler-sdk_FOUND)
|
||||
target_compile_definitions(TracyClient PUBLIC TRACY_ROCPROF)
|
||||
target_link_libraries(TracyClient PUBLIC rocprofiler-sdk::rocprofiler-sdk)
|
||||
endif()
|
||||
|
||||
if(TRACY_Fortran)
|
||||
add_library(TracyClientF90 ${TRACY_VISIBILITY} "${TRACY_PUBLIC_DIR}/TracyClient.F90")
|
||||
|
||||
Reference in New Issue
Block a user