mirror of
https://git.savannah.gnu.org/git/guix.git
synced 2026-04-06 21:20:33 +02:00
gnu: Add virt-what.
* gnu/packages/virtualization.scm (virt-what): New variable. Change-Id: I8fee626b3525dd4b81b2cd1dc3628f090af8d84b Co-authored-by: Nguyễn Gia Phong <cnx@loang.net>
This commit is contained in:
@@ -38,11 +38,12 @@
|
||||
;;; Copyright © 2024 jgart <jgart@dismail.de>
|
||||
;;; Copyright © 2024, 2025 Ashish SHUKLA <ashish.is@lostca.se>
|
||||
;;; Copyright © 2024 Jakob Kirsch <jakob.kirsch@web.de>
|
||||
;;; Copyright © 2024, 2025 Giacomo Leidi <therewasa@fishinthecalculator.me>
|
||||
;;; Copyright © 2024-2026 Giacomo Leidi <therewasa@fishinthecalculator.me>
|
||||
;;; Copyright © 2024 Artyom V. Poptsov <poptsov.artyom@gmail.com>
|
||||
;;; Copyright © 2025 Karl Hallsby <karl@hallsby.com>
|
||||
;;; Copyright © 2025 Douglas Deslauriers <Douglas.Deslauriers@vector.com>
|
||||
;;; Copyright © 2025 Andreas Enge <andreas@enge.fr>
|
||||
;;; Copyright © 2026 Nguyễn Gia Phong <cnx@loang.net>
|
||||
;;;
|
||||
;;; This file is part of GNU Guix.
|
||||
;;;
|
||||
@@ -3858,3 +3859,45 @@ create_header"))))))))))
|
||||
libxcrypt
|
||||
numactl
|
||||
yajl)))))
|
||||
|
||||
(define-public virt-what
|
||||
(package
|
||||
(name "virt-what")
|
||||
(version "1.27")
|
||||
(source (origin
|
||||
(method url-fetch)
|
||||
(uri (string-append "https://people.redhat.com/~rjones/virt-what/"
|
||||
"files/" name "-" version ".tar.gz"))
|
||||
(sha256
|
||||
(base32
|
||||
"1wcvqs5g6b86bym75f1h8gmwf5ak95iwdyj3ficrb4759afvvnfl"))))
|
||||
(build-system gnu-build-system)
|
||||
(arguments
|
||||
(list #:phases
|
||||
#~(modify-phases %standard-phases
|
||||
(add-after 'install 'wrap-binaries
|
||||
(lambda* (#:key inputs #:allow-other-keys)
|
||||
(substitute* (string-append #$output "/sbin/virt-what")
|
||||
(("^PATH=\".*\"")
|
||||
(simple-format #f "PATH=\"~a\""
|
||||
(string-join
|
||||
(search-path-as-list '("bin" "sbin" "libexec")
|
||||
(cons #$output (map cdr inputs)))
|
||||
":")))))))))
|
||||
(native-inputs
|
||||
(list perl))
|
||||
(inputs
|
||||
(list coreutils
|
||||
bash-minimal
|
||||
dmidecode
|
||||
util-linux
|
||||
which))
|
||||
(home-page "https://people.redhat.com/~rjones/virt-what/")
|
||||
(synopsis "Detect if running in a virtual machine")
|
||||
(description
|
||||
"@code{virt-what} is a program which can be used to detect if the program
|
||||
is running in a virtual machine.
|
||||
|
||||
The program prints out a list of \"facts\" about the virtual machine,
|
||||
derived from heuristics. One fact is printed per line.")
|
||||
(license license:gpl2+)))
|
||||
|
||||
Reference in New Issue
Block a user