gnu: python-pyusb: Prettify library substitution.
* gnu/packages/libusb.scm (python-pyusb)[arguments]: Use srfi-1 to make the "fix-libusb-reference" phase clearer.
This commit is contained in:
parent
bae678296a
commit
67a3b2dd4e
|
@ -105,7 +105,8 @@ (define-public python-pyusb
|
||||||
(build-system python-build-system)
|
(build-system python-build-system)
|
||||||
(arguments
|
(arguments
|
||||||
`(#:tests? #f ;no tests
|
`(#:tests? #f ;no tests
|
||||||
#:modules ((srfi srfi-26)
|
#:modules ((srfi srfi-1)
|
||||||
|
(srfi srfi-26)
|
||||||
(guix build utils)
|
(guix build utils)
|
||||||
(guix build python-build-system))
|
(guix build python-build-system))
|
||||||
#:phases
|
#:phases
|
||||||
|
@ -116,11 +117,9 @@ (define-public python-pyusb
|
||||||
(("lib = locate_library\\(candidates, find_library\\)")
|
(("lib = locate_library\\(candidates, find_library\\)")
|
||||||
(string-append
|
(string-append
|
||||||
"lib = \""
|
"lib = \""
|
||||||
(car (find-files (assoc-ref inputs "libusb")
|
(find (negate symbolic-link?)
|
||||||
(lambda (file stat)
|
(find-files (assoc-ref inputs "libusb")
|
||||||
(and ((file-name-predicate
|
"^libusb-.*\\.so\\..*"))
|
||||||
"^libusb-.*\\.so\\..*") file stat)
|
|
||||||
(not (symbolic-link? file))))))
|
|
||||||
"\"")))
|
"\"")))
|
||||||
#t)))))
|
#t)))))
|
||||||
(inputs
|
(inputs
|
||||||
|
|
Loading…
Reference in a new issue