aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/attr.scm
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/packages/attr.scm')
-rw-r--r--gnu/packages/attr.scm47
1 files changed, 29 insertions, 18 deletions
diff --git a/gnu/packages/attr.scm b/gnu/packages/attr.scm
index 254792f4ed..3fb15d235f 100644
--- a/gnu/packages/attr.scm
+++ b/gnu/packages/attr.scm
@@ -52,26 +52,37 @@
"install"
"install-lib"
"install-dev")))
- (alist-replace
- 'check
- (lambda _
- ;; Use the right shell.
- (substitute* "test/run"
- (("/bin/sh")
- (which "bash")))
- (system* "make" "tests" "-C" "test")
+ ;; When building natively, adjust the test cases.
+ ,(if (%current-target-system)
+ '%standard-cross-phases
+ '(alist-replace 'check
+ (lambda _
+ ;; Use the right shell.
+ (substitute* "test/run"
+ (("/bin/sh")
+ (which "bash")))
- ;; XXX: Ignore the test result since this is dependent on the
- ;; underlying file system.
- #t)
- %standard-phases)))))
- (inputs `(("perl" ,perl)
- ("gettext" ,guix:gettext)))
- (home-page
- "http://savannah.nongnu.org/projects/attr/")
- (synopsis
- "Library and tools for manipulating extended attributes")
+ (system* "make" "tests" "-C" "test")
+
+ ;; XXX: Ignore the test result since this is
+ ;; dependent on the underlying file system.
+ #t)
+ %standard-phases))))))
+ (inputs `(;; Perl is needed to run tests; remove it from cross builds.
+ ,@(if (%current-target-system)
+ '()
+ `(("perl" ,perl)
+ ("gettext" ,guix:gettext)))))
+ (native-inputs
+ ;; FIXME: Upon next core-updates, make gettext a native input
+ ;; unconditionally.
+ (if (%current-target-system)
+ `(("gettext" ,guix:gettext))
+ '()))
+
+ (home-page "http://savannah.nongnu.org/projects/attr/")
+ (synopsis "Library and tools for manipulating extended attributes")
(description
"Portable library and tools for manipulating extended attributes.")
(license (list gpl2+ lgpl2.1+))))