gnu: usbguard: Remove input labels.

* gnu/packages/hardware.scm (usbguard)[native-inputs, inputs]: Remove labels.
[arguments]: Use SEARCH-INPUT-FILE and remove trailing #t's.
This commit is contained in:
Marius Bakke 2022-02-03 18:51:02 +01:00
parent 678c5bea3a
commit 0945e43bf7
No known key found for this signature in database
GPG key ID: A2A06DF2A33A54FA

View file

@ -837,7 +837,7 @@ (define-public usbguard
(base32 "0rc0213qsfap3sgx9m3m1kppxbjl2fdwmzlbn5rbmn1i33125dfi")))) (base32 "0rc0213qsfap3sgx9m3m1kppxbjl2fdwmzlbn5rbmn1i33125dfi"))))
(build-system gnu-build-system) (build-system gnu-build-system)
(arguments (arguments
`(#:phases '(#:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(add-after 'unpack 'patch-bootstrap-script (add-after 'unpack 'patch-bootstrap-script
(lambda _ (lambda _
@ -849,19 +849,17 @@ (define-public usbguard
(lambda* (#:key inputs #:allow-other-keys) (lambda* (#:key inputs #:allow-other-keys)
(substitute* "configure" (substitute* "configure"
(("/usr/include/catch") (("/usr/include/catch")
(string-append (assoc-ref inputs "catch") "/include"))) (dirname (search-input-file inputs "include/catch.hpp"))))
;; Do not create log directory. ;; Do not create log directory.
(substitute* "Makefile.in" ((".*/log/usbguard.*") "")) (substitute* "Makefile.in" ((".*/log/usbguard.*") ""))
;; Disable LDAP tests: they use 'sudo'. ;; Disable LDAP tests: they use 'sudo'.
(substitute* "src/Tests/Makefile.in" (substitute* "src/Tests/Makefile.in"
(("\\$\\(am__append_2\\)") "")) (("\\$\\(am__append_2\\)") ""))))
#t))
(add-after 'install 'delete-static-library (add-after 'install 'delete-static-library
(lambda* (#:key outputs #:allow-other-keys) (lambda* (#:key outputs #:allow-other-keys)
;; It can't be direclty disabled since it's needed for the tests. ;; It can't be direclty disabled since it's needed for the tests.
(delete-file (string-append (assoc-ref outputs "out") (delete-file (string-append (assoc-ref outputs "out")
"/lib/libusbguard.a")) "/lib/libusbguard.a"))))
#t))
(add-after 'install 'install-zsh-completion (add-after 'install 'install-zsh-completion
(lambda* (#:key outputs #:allow-other-keys) (lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out")) (let* ((out (assoc-ref outputs "out"))
@ -869,8 +867,7 @@ (define-public usbguard
(string-append out "/share/zsh/site-functions"))) (string-append out "/share/zsh/site-functions")))
(mkdir-p site-functions) (mkdir-p site-functions)
(copy-file "scripts/usbguard-zsh-completion" (copy-file "scripts/usbguard-zsh-completion"
(string-append site-functions "/_usbguard")) (string-append site-functions "/_usbguard"))))))
#t))))
#:make-flags #:make-flags
(list (string-append "BASH_COMPLETION_DIR=" (list (string-append "BASH_COMPLETION_DIR="
(assoc-ref %outputs "out") (assoc-ref %outputs "out")
@ -883,28 +880,28 @@ (define-public usbguard
"--with-dbus" "--with-dbus"
"--with-polkit"))) "--with-polkit")))
(inputs (inputs
`(("audit" ,audit) (list audit
("catch" ,catch-framework) catch-framework
("dbus-glib" ,dbus-glib) dbus-glib
("ldap" ,openldap) openldap
("libcap-ng" ,libcap-ng) libcap-ng
("libseccomp" ,libseccomp) libseccomp
("libsodium" ,libsodium) libsodium
("pegtl" ,pegtl) pegtl
("polkit" ,polkit) polkit
("protobuf" ,protobuf) protobuf
("libqb" ,libqb))) libqb))
(native-inputs (native-inputs
`(("asciidoc" ,asciidoc) (list asciidoc
("autoconf" ,autoconf) autoconf
("automake" ,automake) automake
("libtool" ,libtool) libtool
("bash-completion" ,bash-completion) bash-completion
("gdbus-codegen" ,glib "bin") `(,glib "bin")
("umockdev" ,umockdev) umockdev
("xmllint" ,libxml2) libxml2
("xsltproc" ,libxslt) libxslt
("pkg-config" ,pkg-config))) pkg-config))
(home-page "https://usbguard.github.io") (home-page "https://usbguard.github.io")
(synopsis "Helps to protect your computer against rogue USB devices (a.k.a. BadUSB)") (synopsis "Helps to protect your computer against rogue USB devices (a.k.a. BadUSB)")
(description "USBGuard is a software framework for implementing USB device (description "USBGuard is a software framework for implementing USB device