;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com>
+;;; Copyright © 2015 Mark H Weaver <mhw@netris.org>
+;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il>
;;;
;;; This file is part of GNU Guix.
;;;
(define-public ninja
(package
(name "ninja")
- (version "1.5.3")
+ (version "1.7.1")
(source (origin
(method url-fetch)
(uri (string-append "https://github.com/martine/ninja/"
(file-name (string-append name "-" version ".tar.gz"))
(sha256
(base32
- "1h3yfwcfl61v493vna6jia2fizh8rpig7qw2504cvkr6gid3p5bw"))
- (patches (list (search-patch "ninja-tests.patch")))))
+ "06dy2dc1aafm61ynw9gzig88la3km9dsh53bxf4mnw7l7kjisn2i"))
+ (patches (search-patches "ninja-zero-mtime.patch"
+ "ninja-tests.patch"))))
(build-system gnu-build-system)
+ (native-inputs `(("python" ,python-2)))
(arguments
'(#:phases
- (alist-replace
- 'configure
- (lambda _
- (substitute* "src/subprocess-posix.cc"
- (("/bin/sh") (which "sh"))))
- (alist-replace
- 'build
- (lambda _
- (zero? (system* "./configure.py" "--bootstrap")))
- (alist-replace
+ (modify-phases %standard-phases
+ (replace
+ 'configure
+ (lambda _
+ (substitute* "src/subprocess-posix.cc"
+ (("/bin/sh") (which "sh")))
+ #t))
+ (replace
+ 'build
+ (lambda _
+ (zero? (system* "./configure.py" "--bootstrap"))))
+ (replace
'check
(lambda _
(and (zero? (system* "./configure.py"))
(zero? (system* "./ninja" "ninja_test"))
- (zero? (system* "./ninja_test"))))
- (alist-replace
- 'install
- (lambda* (#:key outputs #:allow-other-keys)
- (let* ((out (assoc-ref outputs "out"))
- (bin (string-append out "/bin"))
- (doc (string-append out "/share/doc/ninja")))
- (mkdir-p bin)
- (copy-file "ninja" (string-append bin "/ninja"))
- (mkdir-p doc)
- (copy-file "doc/manual.asciidoc"
- (string-append doc "/manual.asciidoc"))))
- %standard-phases))))))
- (native-inputs `(("python" ,python-2)))
- (home-page "http://martine.github.io/ninja/")
+ (zero? (system* "./ninja_test")))))
+ (replace
+ 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (bin (string-append out "/bin"))
+ (doc (string-append out "/share/doc/ninja")))
+ (install-file "ninja" bin)
+ (install-file "doc/manual.asciidoc" doc)
+ #t))))))
+ (home-page "https://ninja-build.org/")
(synopsis "Small build system")
(description
"Ninja is a small build system with a focus on speed. It differs from