gnu: zip: Improve build process and install man pages in share/man.

* gnu/packages/zip.scm (zip): Eliminate custom configure phase which copied
  and patched the Makefile.  Instead add "-f" and "prefix" to make-flags, as
  well as "MANDIR".  Remove "generic_gcc" from the make-flags, so that it will
  not be passed during other phases involving 'make'.  Instead replace the
  'build' phase with one that specifies the "generic_gcc" target.
This commit is contained in:
Mark H Weaver 2014-04-01 17:36:30 -04:00
parent a2c03fb1af
commit 7575778969

View file

@ -43,15 +43,15 @@ (define-public zip
(inputs `(("bzip2" ,bzip2)))
(arguments
`(#:tests? #f ; no test target
#:make-flags '("generic_gcc")
#:phases
(alist-replace
'configure
(lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out")))
(copy-file "unix/Makefile" "Makefile")
(substitute* "Makefile" (("/usr/local") out))))
%standard-phases)))
#:make-flags (let ((out (assoc-ref %outputs "out")))
(list "-f" "unix/Makefile"
(string-append "prefix=" out)
(string-append "MANDIR=" out "/share/man/man1")))
#:phases (alist-replace
'build
(lambda* (#:key (make-flags '()) #:allow-other-keys)
(zero? (apply system* "make" "generic_gcc" make-flags)))
(alist-delete 'configure %standard-phases))))
(home-page "http://www.info-zip.org/Zip.html")
(synopsis "Zip compression and file packing utility")
(description