guix_mirror_bot pushed a commit to branch master
in repository guix.
commit 41c945bd13f76f2f1b8a93423cd7d61d86d06a42
Author: David Elsing <[email protected]>
AuthorDate: Tue Feb 3 21:33:21 2026 +0100
gnu: Add rocprofiler-register.
Adapted from the Guix-HPC channel
(https://gitlab.inria.fr/guix-hpc/guix-hpc).
* gnu/packages/rocm.scm (rocprofiler-register): New variable.
Signed-off-by: Ludovic Courtès <[email protected]>
---
gnu/packages/rocm.scm | 42 ++++++++++++++++++++++++++++++++++++++++++
1 file changed, 42 insertions(+)
diff --git a/gnu/packages/rocm.scm b/gnu/packages/rocm.scm
index baa04b9e01..50a4f9158e 100644
--- a/gnu/packages/rocm.scm
+++ b/gnu/packages/rocm.scm
@@ -2,6 +2,8 @@
;;; Copyright © 2021 Lars-Dominik Braun <[email protected]>
;;; Copyright © 2022, 2023, 2025 John Kehayias <[email protected]>
;;; Copyright © 2026 Jean-Baptiste Note <[email protected]>
+;;; Copyright © 2023 Advanced Micro Devices, Inc.
+;;; Copyright © 2026 David Elsing <[email protected]>
;;;
;;; This program is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU General Public License as published by
@@ -531,3 +533,43 @@ applications to control GPU operations, monitor
performance, and retrieve
information about the system's drivers and GPUs. It also provides a
command-line tool, @command{amd-smi}, which can be used to do the same.")
(license (list license:expat license:ncsa))))
+
+(define-public rocprofiler-register
+ (package
+ (name "rocprofiler-register")
+ (version %rocm-version)
+ (source %rocm-systems-origin)
+ (build-system cmake-build-system)
+ (arguments
+ (list
+ #:configure-flags
+ #~(list
+ "-DROCPROFILER_REGISTER_BUILD_GLOG=OFF"
+ "-DROCPROFILER_REGISTER_BUILD_FMT=OFF"
+ "-DROCPROFILER_REGISTER_BUILD_TESTS=ON")
+ #:phases
+ '(modify-phases %standard-phases
+ (add-after 'unpack 'chdir
+ (lambda _
+ (chdir "projects/rocprofiler-register")))
+ (add-after 'chdir 'patch-cmake
+ (lambda _
+ (substitute* "CMakeLists.txt"
+ (("find_package\\(Git.*") ""))
+ (substitute* "cmake/rocprofiler_register_config_packaging.cmake"
+ (("set\\(_DESC.*" orig)
+ (string-append orig "\ninclude(CPack)\n")))
+ (substitute* "source/lib/rocprofiler-register/CMakeLists.txt"
+ (("target_link_libraries" orig)
+ (string-append
+ "find_package(fmt REQUIRED)\n"
+ "find_package(glog REQUIRED)\n"
+ orig))))))))
+ (inputs (list glog-next))
+ (native-inputs (list fmt-11))
+ (home-page %rocm-systems-url)
+ (synopsis "Support library to be used with rocprofiler")
+ (description "The rocprofiler-register library coordinates the
+modification of the intercept API table(s) of the HSA/HIP/ROCTx
+runtime libraries by the ROCprofiler (v2) library.")
+ (license license:expat)))