diff options
author | V3n3RiX <venerix@koprulu.sector> | 2023-01-31 21:02:55 +0000 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2023-01-31 21:02:55 +0000 |
commit | d36c5f9e59f92a021c987989cd79d44460e0da42 (patch) | |
tree | 2504c88d1f287ac3a71ebc56e5d19f34a2c1b9a4 /dev-util/roctracer/files | |
parent | e860dfa5acdb67f8e2b8938b005dbaaaaf2c984a (diff) |
gentoo auto-resync : 31:01:2023 - 21:02:55
Diffstat (limited to 'dev-util/roctracer/files')
3 files changed, 83 insertions, 0 deletions
diff --git a/dev-util/roctracer/files/roctracer-5.3.3-do-not-install-test-files.patch b/dev-util/roctracer/files/roctracer-5.3.3-do-not-install-test-files.patch new file mode 100644 index 000000000000..ac3e53c1f405 --- /dev/null +++ b/dev-util/roctracer/files/roctracer-5.3.3-do-not-install-test-files.patch @@ -0,0 +1,37 @@ +Remove all install commands for test +=================================================================== +--- roctracer-rocm-5.3.3.orig/test/CMakeLists.txt ++++ roctracer-rocm-5.3.3/test/CMakeLists.txt +@@ -87,7 +87,6 @@ function(generate_hsaco TARGET_ID INPUT_ + DEPENDS ${INPUT_FILE} clang + COMMENT "Building ${OUTPUT_FILE}..." + VERBATIM) +- install(FILES ${PROJECT_BINARY_DIR}/${OUTPUT_FILE} DESTINATION test/${PROJECT_NAME} COMPONENT tests) + set(HSACO_TARGET_LIST ${HSACO_TARGET_LIST} ${PROJECT_BINARY_DIR}/${OUTPUT_FILE} PARENT_SCOPE) + endfunction(generate_hsaco) + +@@ -150,24 +149,10 @@ add_dependencies(mytest dlopen) + ## Copy the golden traces and test scripts + configure_file(run.sh ${PROJECT_BINARY_DIR} COPYONLY) + execute_process(COMMAND ${CMAKE_COMMAND} -E create_symlink run.sh ${PROJECT_BINARY_DIR}/run_ci.sh) +-install(PROGRAMS ${PROJECT_BINARY_DIR}/run.sh DESTINATION test/${PROJECT_NAME} COMPONENT tests) + + configure_file(${PROJECT_SOURCE_DIR}/script/check_trace.py ${PROJECT_BINARY_DIR}/test/check_trace.py COPYONLY) +-install(PROGRAMS ${PROJECT_BINARY_DIR}/test/check_trace.py DESTINATION test/${PROJECT_NAME}/test COMPONENT tests) + + file(GLOB files RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} "golden_traces/tests_trace_cmp_levels.txt" "golden_traces/*_trace.txt") + foreach(file ${files}) + configure_file(${file} ${PROJECT_BINARY_DIR}/test/${file} COPYONLY) + endforeach() +-install(DIRECTORY ${PROJECT_BINARY_DIR}/test/golden_traces DESTINATION test/${PROJECT_NAME}/test COMPONENT tests) +- +-# install all executables +-set(all_executables) +-get_property(all_targets DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} PROPERTY BUILDSYSTEM_TARGETS) +-foreach(target IN LISTS all_targets) +- get_target_property(target_type ${target} TYPE) +- if (target_type STREQUAL "EXECUTABLE") +- list(APPEND all_executables ${target}) +- endif() +-endforeach() +-install(TARGETS ${all_executables} DESTINATION test/${PROJECT_NAME}/test COMPONENT tests) diff --git a/dev-util/roctracer/files/roctracer-5.3.3-flat-lib-layout.patch b/dev-util/roctracer/files/roctracer-5.3.3-flat-lib-layout.patch new file mode 100644 index 000000000000..46c8d1a168b8 --- /dev/null +++ b/dev-util/roctracer/files/roctracer-5.3.3-flat-lib-layout.patch @@ -0,0 +1,34 @@ +Install libs directly into /usr/lib64 +=================================================================== +Index: roctracer-rocm-5.3.3/src/CMakeLists.txt +=================================================================== +--- roctracer-rocm-5.3.3.orig/src/CMakeLists.txt ++++ roctracer-rocm-5.3.3/src/CMakeLists.txt +@@ -215,12 +215,12 @@ target_include_directories(roctracer_too + target_link_libraries(roctracer_tool util roctracer hsa-runtime64::hsa-runtime64 stdc++fs Threads::Threads atomic dl) + target_link_options(roctracer_tool PRIVATE -Wl,--version-script=${CMAKE_CURRENT_SOURCE_DIR}/tracer_tool/exportmap -Wl,--no-undefined) + +-install(TARGETS roctracer_tool LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/${PROJECT_NAME} COMPONENT runtime) ++install(TARGETS roctracer_tool LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT runtime) + + add_library(hip_stats SHARED hip_stats/hip_stats.cpp) + target_compile_definitions(hip_stats PRIVATE __HIP_PLATFORM_AMD__) + target_link_libraries(hip_stats roctracer stdc++fs) +-install(TARGETS hip_stats LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/${PROJECT_NAME} COMPONENT runtime) ++install(TARGETS hip_stats LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT runtime) + + endif() + +Index: roctracer-rocm-5.3.3/plugin/file/CMakeLists.txt +=================================================================== +--- roctracer-rocm-5.3.3.orig/plugin/file/CMakeLists.txt ++++ roctracer-rocm-5.3.3/plugin/file/CMakeLists.txt +@@ -38,5 +38,5 @@ target_link_options(file_plugin PRIVATE + target_link_libraries(file_plugin PRIVATE util roctracer hsa-runtime64::hsa-runtime64 stdc++fs) + + install(TARGETS file_plugin LIBRARY +- DESTINATION ${CMAKE_INSTALL_LIBDIR}/${PROJECT_NAME} +- COMPONENT runtime) +\ No newline at end of file ++ DESTINATION ${CMAKE_INSTALL_LIBDIR} ++ COMPONENT runtime) diff --git a/dev-util/roctracer/files/roctracer-5.3.3-rocm-path.patch b/dev-util/roctracer/files/roctracer-5.3.3-rocm-path.patch new file mode 100644 index 000000000000..d8cc792b4dbb --- /dev/null +++ b/dev-util/roctracer/files/roctracer-5.3.3-rocm-path.patch @@ -0,0 +1,12 @@ +Append flags for clang to recognize device lib path +=================================================================== +--- roctracer-rocm-5.3.3.orig/test/CMakeLists.txt ++++ roctracer-rocm-5.3.3/test/CMakeLists.txt +@@ -80,6 +80,7 @@ add_dependencies(mytest codeobj_test) + function(generate_hsaco TARGET_ID INPUT_FILE OUTPUT_FILE) + separate_arguments(CLANG_ARG_LIST UNIX_COMMAND + "-O2 -x cl -Xclang -finclude-default-header -cl-denorms-are-zero -cl-std=CL2.0 -Wl,--build-id=sha1 ++ --rocm-path=@GENTOO_PORTAGE_EPREFIX@/usr --rocm-device-lib-path=@GENTOO_PORTAGE_EPREFIX@/usr/lib/amdgcn/bitcode + -target amdgcn-amd-amdhsa -mcpu=${TARGET_ID} -o ${OUTPUT_FILE} ${INPUT_FILE}") + add_custom_command(OUTPUT ${PROJECT_BINARY_DIR}/${OUTPUT_FILE} + COMMAND clang ${CLANG_ARG_LIST} |