diff --git a/.github/workflows/therock-ci-linux.yml b/.github/workflows/therock-ci-linux.yml index eed78f6e31..8e0122885a 100644 --- a/.github/workflows/therock-ci-linux.yml +++ b/.github/workflows/therock-ci-linux.yml @@ -66,6 +66,7 @@ jobs: run: | # Remove patches here if they cannot be applied cleanly, and they have not been deleted from TheRock repo # rm ./TheRock/patches/amd-mainline/rocm-systems/*.patch + rm ./TheRock/patches/amd-mainline/rocm-systems/0008-Find-bundled-libelf.patch ./TheRock/build_tools/fetch_sources.py --jobs 12 --no-include-rocm-systems --no-include-rocm-libraries --no-include-ml-frameworks diff --git a/.github/workflows/therock-ci-windows.yml b/.github/workflows/therock-ci-windows.yml index 7f9f4ada5a..072bfa5bd6 100644 --- a/.github/workflows/therock-ci-windows.yml +++ b/.github/workflows/therock-ci-windows.yml @@ -54,6 +54,7 @@ jobs: run: | # Remove patches here if they cannot be applied cleanly, and they have not been deleted from TheRock repo # rm ./TheRock/patches/amd-mainline/rocm-systems/*.patch + rm ./TheRock/patches/amd-mainline/rocm-systems/0008-Find-bundled-libelf.patch git -c user.name="therockbot" -c "user.email=therockbot@amd.com" am --whitespace=nowarn ./TheRock/patches/amd-mainline/rocm-systems/*.patch - name: Install requirements diff --git a/projects/rocprofiler-sdk/cmake/rocprofiler_config_interfaces.cmake b/projects/rocprofiler-sdk/cmake/rocprofiler_config_interfaces.cmake index 8aadc8dcff..0c9e2cda18 100644 --- a/projects/rocprofiler-sdk/cmake/rocprofiler_config_interfaces.cmake +++ b/projects/rocprofiler-sdk/cmake/rocprofiler_config_interfaces.cmake @@ -198,8 +198,13 @@ target_link_libraries(rocprofiler-sdk-ptl INTERFACE PTL::ptl-static) # # ----------------------------------------------------------------------------------------# -find_package(libelf REQUIRED) -target_link_libraries(rocprofiler-sdk-elf INTERFACE libelf::libelf) +find_package(LibElf) +if(LibElf_FOUND) + target_link_libraries(rocprofiler-sdk-elf INTERFACE elf::elf) +else() + find_package(libelf REQUIRED) + target_link_libraries(rocprofiler-sdk-elf INTERFACE libelf::libelf) +endif() # ----------------------------------------------------------------------------------------# #