Something went wrong. Try again.
lol
Something went wrong. Try again.
2.7 kB · 81 lines
at master
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182diff --git a/test/CMakeLists.txt b/test/CMakeLists.txtindex a923cad..53b0f49 100644--- a/test/CMakeLists.txt+++ b/test/CMakeLists.txt@@ -34,13 +34,7 @@ if(DISABLE_COMGR) endif() if(NOT APPLE AND BUILD_INTEGRATION_TESTS)- # Add nlohmann JSON as an external dependency- include(FetchContent)- FetchContent_Declare(- json- GIT_REPOSITORY https://github.com/nlohmann/json.git- GIT_TAG v3.11.3)- FetchContent_MakeAvailable(json)+ find_package(nlohmann_json REQUIRED) add_subdirectory(att-tool) endif()diff --git a/test/att-tool/CMakeLists.txt b/test/att-tool/CMakeLists.txtindex 208af16..acd161f 100644--- a/test/att-tool/CMakeLists.txt+++ b/test/att-tool/CMakeLists.txt@@ -1,7 +1,7 @@ # # ATT decoder wrapper library for use by the rocprofv3 tool #-find_library(COMGR REQUIRED NAMES amd_comgr HINTS /opt/rocm/lib)+find_library(COMGR REQUIRED NAMES amd_comgr) set(ATT_TOOL_SOURCE_FILES waitcnt/analysis.cpp@@ -19,8 +19,11 @@ set(ATT_TOOL_SOURCE_FILES set(DECODER_SRC ${CMAKE_CURRENT_SOURCE_DIR}/../../source/) -set(INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/../../include/ ${DECODER_SRC} ${CMAKE_CURRENT_SOURCE_DIR} ${json_SOURCE_DIR}/include /opt/rocm/include)-set(LINK_LIBS ${COMGR} pthread)+set(INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/../../include/ ${DECODER_SRC} ${CMAKE_CURRENT_SOURCE_DIR})+find_path(COMGR_INCLUDE_DIR REQUIRED NAMES amd_comgr.h PATH_SUFFIXES amd_comgr)+find_path(HSA_INCLUDE_DIR REQUIRED NAMES hsa/amd_hsa_elf.h)+set(LINK_LIBS ${COMGR} pthread nlohmann_json::nlohmann_json)+list(APPEND INCLUDE_DIRS ${COMGR_INCLUDE_DIR} ${HSA_INCLUDE_DIR}) # Sources re-globbed only for sanitizer builds file(GLOB ATT_DECODER_V3_FILESdiff --git a/test/att-tool/sdk/disassembly.hpp b/test/att-tool/sdk/disassembly.hppindex c054143..ec3d6d2 100644--- a/test/att-tool/sdk/disassembly.hpp+++ b/test/att-tool/sdk/disassembly.hpp@@ -22,7 +22,7 @@ #pragma once -#include <amd_comgr/amd_comgr.h>+#include <amd_comgr.h> #include <hsa/amd_hsa_elf.h> #include <fcntl.h>diff --git a/test/unit/CMakeLists.txt b/test/unit/CMakeLists.txtindex 8adafc0..9501efe 100644--- a/test/unit/CMakeLists.txt+++ b/test/unit/CMakeLists.txt@@ -9,16 +9,7 @@ project(att-decoder-unit-tests LANGUAGES CXX) set(CMAKE_CXX_STANDARD 17) set(CMAKE_CXX_STANDARD_REQUIRED ON) -# Fetch GoogleTest-include(FetchContent)-FetchContent_Declare(- googletest- GIT_REPOSITORY https://github.com/google/googletest.git- GIT_TAG v1.14.0)-set(INSTALL_GTEST- OFF- CACHE BOOL "" FORCE)-FetchContent_MakeAvailable(googletest)+find_package(GTest REQUIRED) enable_testing()