guix_mirror_bot pushed a commit to branch master
in repository guix.

commit 8be8a7eda6f971e7984ead25260342dcfb8d5217
Author: David Elsing <[email protected]>
AuthorDate: Tue Feb 3 21:33:21 2026 +0100

    gnu: Add rocm-smi.
    
    Adapted from the Guix-HPC channel 
(https://gitlab.inria.fr/guix-hpc/guix-hpc).
    
    * gnu/packages/rocm-tools.scm (rocm-smi): New variable.
    
    Signed-off-by: Ludovic Courtès <[email protected]>
---
 gnu/packages/rocm-tools.scm | 33 +++++++++++++++++++++++++++++++++
 1 file changed, 33 insertions(+)

diff --git a/gnu/packages/rocm-tools.scm b/gnu/packages/rocm-tools.scm
index 6ac4d5b851..f2331c1104 100644
--- a/gnu/packages/rocm-tools.scm
+++ b/gnu/packages/rocm-tools.scm
@@ -21,6 +21,7 @@
   #:use-module (guix git-download)
   #:use-module ((guix licenses) #:prefix license:)
   #:use-module (guix packages)
+  #:use-module (gnu packages base)
   #:use-module (gnu packages check)
   #:use-module (gnu packages elf)
   #:use-module (gnu packages instrumentation)
@@ -29,10 +30,12 @@
   #:use-module (gnu packages llvm)
   #:use-module (gnu packages pciutils)
   #:use-module (gnu packages perl)
+  #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages python)
   #:use-module (gnu packages python-science)
   #:use-module (gnu packages python-xyz)
   #:use-module (gnu packages rocm)
+  #:use-module (gnu packages xdisorg)
   #:use-module (gnu packages xml)
   #:use-module (gnu packages xorg))
 
@@ -167,3 +170,33 @@ translate CUDA source code into portable HIP C++.")
     (description "ROC profiler library.  Profiling with perf-counters
 and derived metrics.")
     (license license:expat)))
+
+(define-public rocm-smi
+  (package
+    (name "rocm-smi")
+    (version %rocm-version)
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+              (url (string-append "https://github.com/ROCm/rocm_smi_lib";))
+              (commit (string-append "rocm-" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32
+         "16i9ki4h6qp05g2n8pn8zakic8x581c1aavwnbyf17rrxvbnhyzz"))))
+    (build-system cmake-build-system)
+    (arguments
+     (list
+      #:tests? #f ; requires GPU
+      #:build-type "Release"))
+    (native-inputs (list pkg-config))
+    (inputs (list libdrm python))
+    (propagated-inputs (list grep coreutils))
+    (synopsis "The ROCm System Management Interface (ROCm SMI) Library")
+    (description "The ROCm System Management Interface Library, or
+ROCm SMI library, is part of the Radeon Open Compute ROCm software
+stack.  It is a C library for Linux that provides a user space
+interface for applications to monitor and control GPU applications.")
+    (home-page "https://github.com/ROCm/rocm_smi_lib";)
+    (license license:ncsa)))

Reply via email to