gnu: rmlint: Update package style.

* gnu/packages/disk.scm (rmlint)[arguments]:
Rewrite as G-expressions.
[native-inputs, inputs]: Remove input labels.
This commit is contained in:
Tobias Geerinckx-Rice 2023-08-06 02:00:00 +02:00
parent 02ccc57635
commit 3a1547db2e
No known key found for this signature in database
GPG key ID: 0DB0FF884F556D79

View file

@ -1143,12 +1143,14 @@ (define-public rmlint
"0sk4v1chnk2hvzi92svyf8qgamfs4fvial90qwx4a7dayxhkbsm4")))) "0sk4v1chnk2hvzi92svyf8qgamfs4fvial90qwx4a7dayxhkbsm4"))))
(build-system scons-build-system) (build-system scons-build-system)
(arguments (arguments
`(#:scons ,scons-python2 (list
#:scons-flags (list (string-append "--prefix=" %output) #:scons scons-python2
(string-append "--actual-prefix=" %output)) #:scons-flags
#:tests? #f ; No tests? #~(list (string-append "--prefix=" #$output)
(string-append "--actual-prefix=" #$output))
#:tests? #f ; no tests
#:phases #:phases
(modify-phases %standard-phases #~(modify-phases %standard-phases
(add-after 'unpack 'scons-propagate-environment (add-after 'unpack 'scons-propagate-environment
(lambda* (#:key inputs #:allow-other-keys) (lambda* (#:key inputs #:allow-other-keys)
;; TODO: `rmlint --gui` fails with ;; TODO: `rmlint --gui` fails with
@ -1157,9 +1159,8 @@ (define-public rmlint
;; python-gobject, python-cairo, dconf, librsvg, gtksourceview3. ;; python-gobject, python-cairo, dconf, librsvg, gtksourceview3.
(substitute* "lib/cmdline.c" (substitute* "lib/cmdline.c"
(("const char \\*commands\\[\\] = \\{\"python3\", \"python\", NULL\\};") (("const char \\*commands\\[\\] = \\{\"python3\", \"python\", NULL\\};")
(string-append (string-append "const char *commands[] = {\""
"const char *commands[] = {\"" (search-input-file inputs "/bin/python")
(assoc-ref inputs "python") "/bin/python"
"\", \"python\", NULL};"))) "\", \"python\", NULL};")))
;; By design, SCons does not, by default, propagate ;; By design, SCons does not, by default, propagate
;; environment variables to subprocesses. See: ;; environment variables to subprocesses. See:
@ -1168,20 +1169,16 @@ (define-public rmlint
;; environment variables to be propagated. ;; environment variables to be propagated.
(substitute* "SConstruct" (substitute* "SConstruct"
(("^env = Environment\\(.*\\)" all) (("^env = Environment\\(.*\\)" all)
(string-append (string-append all "\nenv['ENV']=os.environ"))))))))
all
"\nenv['ENV']=os.environ"))))))))
(native-inputs (native-inputs
`(("pkg-config" ,pkg-config) (list `(,glib "bin") pkg-config python-sphinx))
("glib:bin" ,glib "bin")
("python-sphinx" ,python-sphinx)))
(inputs (inputs
`(("python" ,python-wrapper) (list elfutils
("glib" ,glib) glib
("libelf" ,libelf) json-glib
("elfutils" ,elfutils) libelf
("json-glib" ,json-glib) python-wrapper
("libblkid" ,util-linux "lib"))) `(,util-linux "lib")))
(home-page "https://rmlint.rtfd.org") (home-page "https://rmlint.rtfd.org")
(synopsis "Remove duplicates and other lint from the file system") (synopsis "Remove duplicates and other lint from the file system")
(description "@command{rmlint} finds space waste and other broken things (description "@command{rmlint} finds space waste and other broken things