summaryrefslogtreecommitdiff
path: root/gnu/packages/virtualization.scm
diff options
context:
space:
mode:
authorMarius Bakke <marius@gnu.org>2021-12-14 22:42:35 +0100
committerMarius Bakke <marius@gnu.org>2021-12-15 18:43:25 +0100
commitd64bd1254a015dfc999431dc65b6c5f210e8e334 (patch)
treed6251e2a27ab0debf52ea8def937c8622ebc9c04 /gnu/packages/virtualization.scm
parente642378df3b0d218e463397883e7bf331f528c6a (diff)
downloadguix-patches-d64bd1254a015dfc999431dc65b6c5f210e8e334.tar
guix-patches-d64bd1254a015dfc999431dc65b6c5f210e8e334.tar.gz
gnu: qemu: Adjust style.
* gnu/packages/virtualization.scm (qemu)[arguments]: Use SEARCH-INPUT-FILE instead of WHICH. [native-inputs]: Remove labels. [inputs]: Likewise. Add BASH-MINIMAL and remove duplicate ATTR.
Diffstat (limited to 'gnu/packages/virtualization.scm')
-rw-r--r--gnu/packages/virtualization.scm95
1 files changed, 48 insertions, 47 deletions
diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm
index 61c9047989..3b56bfedd6 100644
--- a/gnu/packages/virtualization.scm
+++ b/gnu/packages/virtualization.scm
@@ -213,16 +213,17 @@
((".*'test-char':.*" all)
(string-append "# " all)))))
(add-after 'patch-source-shebangs 'patch-embedded-shebangs
- (lambda _
+ (lambda* (#:key native-inputs inputs #:allow-other-keys)
;; Ensure the executables created by these source files reference
;; /bin/sh from the store so they work inside the build container.
(substitute* '("block/cloop.c" "migration/exec.c"
"net/tap.c" "tests/qtest/libqtest.c"
"tests/qtest/vhost-user-blk-test.c")
- (("/bin/sh") (which "sh")))
+ (("/bin/sh") (search-input-file inputs "/bin/sh")))
(substitute* "tests/qemu-iotests/testenv.py"
(("#!/usr/bin/env python3")
- (string-append "#!" (which "python3"))))))
+ (string-append "#!" (search-input-file (or native-inputs inputs)
+ "/bin/python3"))))))
(add-before 'configure 'fix-optionrom-makefile
(lambda _
;; Work around the inability of the rules defined in this
@@ -304,50 +305,50 @@ exec smbd $@")))
(mkdir-p qemu-doc)
(rename-file (string-append out "/share/doc/qemu")
(string-append qemu-doc "/html"))))))))
- (inputs ; TODO: Add optional inputs.
- `(("alsa-lib" ,alsa-lib)
- ("attr" ,attr)
- ("glib" ,glib)
- ("gtk+" ,gtk+)
- ("libaio" ,libaio)
- ("libattr" ,attr)
- ("libcacard" ,libcacard) ; smartcard support
- ("libcap-ng" ,libcap-ng) ; virtfs support requires libcap-ng & libattr
- ("libdrm" ,libdrm)
- ("libepoxy" ,libepoxy)
- ("libjpeg" ,libjpeg-turbo)
- ("libpng" ,libpng)
- ("libseccomp" ,libseccomp)
- ("libusb" ,libusb) ;USB pass-through support
- ("mesa" ,mesa)
- ("ncurses" ,ncurses)
- ;; ("pciutils" ,pciutils)
- ("pixman" ,pixman)
- ("pulseaudio" ,pulseaudio)
- ("sdl2" ,sdl2)
- ("spice" ,spice)
- ("usbredir" ,usbredir)
- ("util-linux" ,util-linux)
- ("vde2" ,vde2)
- ("virglrenderer" ,virglrenderer)
- ("zlib" ,zlib)))
- (native-inputs `(("gettext" ,gettext-minimal)
- ("glib:bin" ,glib "bin") ; gtester, etc.
- ("perl" ,perl)
- ("flex" ,flex)
- ("bison" ,bison)
- ("meson" ,meson)
- ("ninja" ,ninja)
- ("pkg-config" ,pkg-config)
- ("python-wrapper" ,python-wrapper)
- ("python-sphinx" ,python-sphinx)
- ("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme)
- ("texinfo" ,texinfo)
- ;; The following static libraries are required to build
- ;; the static output of QEMU.
- ("glib:static" ,glib "static")
- ("pcre:static" ,pcre "static")
- ("zlib:static" ,zlib "static")))
+ (inputs
+ (list alsa-lib
+ bash-minimal
+ glib
+ gtk+
+ libaio
+ libcacard ;smartcard support
+ attr libcap-ng ;VirtFS support
+ libdrm
+ libepoxy
+ libjpeg-turbo
+ libpng
+ libseccomp
+ libusb ;USB pass-through support
+ mesa
+ ncurses
+ ;; ("pciutils" ,pciutils)
+ pixman
+ pulseaudio
+ sdl2
+ spice
+ usbredir
+ util-linux
+ vde2
+ virglrenderer
+ zlib))
+ (native-inputs
+ (list gettext-minimal
+ `(,glib "bin") ;gtester, etc.
+ perl
+ flex
+ bison
+ meson
+ ninja
+ pkg-config
+ python-wrapper
+ python-sphinx
+ python-sphinx-rtd-theme
+ texinfo
+ ;; The following static libraries are required to build
+ ;; the static output of QEMU.
+ `(,glib "static")
+ `(,pcre "static")
+ `(,zlib "static")))
(home-page "https://www.qemu.org")
(synopsis "Machine emulator and virtualizer")
(description