gnu: attr: Use 'modify-phases'.
* gnu/packages/attr.scm (attr)[arguments]: Use 'modify-phases'.
This commit is contained in:
parent
209e09fa10
commit
20c620d0a4
|
@ -1,6 +1,6 @@
|
||||||
;;; GNU Guix --- Functional package management for GNU
|
;;; GNU Guix --- Functional package management for GNU
|
||||||
;;; Copyright © 2012 Nikita Karetnikov <nikita@karetnikov.org>
|
;;; Copyright © 2012 Nikita Karetnikov <nikita@karetnikov.org>
|
||||||
;;; Copyright © 2012, 2013 Ludovic Courtès <ludo@gnu.org>
|
;;; Copyright © 2012, 2013, 2016 Ludovic Courtès <ludo@gnu.org>
|
||||||
;;;
|
;;;
|
||||||
;;; This file is part of GNU Guix.
|
;;; This file is part of GNU Guix.
|
||||||
;;;
|
;;;
|
||||||
|
@ -29,45 +29,40 @@
|
||||||
(package
|
(package
|
||||||
(name "attr")
|
(name "attr")
|
||||||
(version "2.4.46")
|
(version "2.4.46")
|
||||||
(source
|
(source (origin
|
||||||
(origin
|
(method url-fetch)
|
||||||
(method url-fetch)
|
(uri (string-append "mirror://savannah/attr/attr-"
|
||||||
(uri (string-append "mirror://savannah/attr/attr-"
|
version ".src.tar.gz"))
|
||||||
version ".src.tar.gz"))
|
(sha256
|
||||||
(sha256
|
(base32
|
||||||
(base32
|
"07qf6kb2zk512az481bbnsk9jycn477xpva1a726n5pzlzf9pmnw"))))
|
||||||
"07qf6kb2zk512az481bbnsk9jycn477xpva1a726n5pzlzf9pmnw"))))
|
|
||||||
(build-system gnu-build-system)
|
(build-system gnu-build-system)
|
||||||
(arguments
|
(arguments
|
||||||
`(#:phases
|
`(#:phases
|
||||||
(alist-cons-after
|
(modify-phases %standard-phases
|
||||||
'configure 'patch-makefile-SHELL
|
(add-after 'configure 'patch-makefile-SHELL
|
||||||
(lambda _
|
(lambda _
|
||||||
(patch-makefile-SHELL "include/buildmacros"))
|
(patch-makefile-SHELL "include/buildmacros")))
|
||||||
(alist-replace
|
(replace 'install
|
||||||
'install
|
(lambda _
|
||||||
(lambda _
|
(zero? (system* "make"
|
||||||
(zero? (system* "make"
|
"install"
|
||||||
"install"
|
"install-lib"
|
||||||
"install-lib"
|
"install-dev"))))
|
||||||
"install-dev")))
|
(replace 'check
|
||||||
|
(lambda* (#:key target #:allow-other-keys)
|
||||||
|
;; Use the right shell.
|
||||||
|
(substitute* "test/run"
|
||||||
|
(("/bin/sh")
|
||||||
|
(which "bash")))
|
||||||
|
|
||||||
;; When building natively, adjust the test cases.
|
;; When building natively, run the tests.
|
||||||
,(if (%current-target-system)
|
(unless target
|
||||||
'%standard-phases
|
(system* "make" "tests" "-C" "test"))
|
||||||
'(alist-replace 'check
|
|
||||||
(lambda _
|
|
||||||
;; Use the right shell.
|
|
||||||
(substitute* "test/run"
|
|
||||||
(("/bin/sh")
|
|
||||||
(which "bash")))
|
|
||||||
|
|
||||||
(system* "make" "tests" "-C" "test")
|
;; XXX: Ignore the test result since this is
|
||||||
|
;; dependent on the underlying file system.
|
||||||
;; XXX: Ignore the test result since this is
|
#t)))))
|
||||||
;; dependent on the underlying file system.
|
|
||||||
#t)
|
|
||||||
%standard-phases))))))
|
|
||||||
(inputs
|
(inputs
|
||||||
;; Perl is needed to run tests; remove it from cross builds.
|
;; Perl is needed to run tests; remove it from cross builds.
|
||||||
(if (%current-target-system)
|
(if (%current-target-system)
|
||||||
|
|
Loading…
Reference in New Issue