diff options
Diffstat (limited to 'gnu/packages/ninja.scm')
-rw-r--r-- | gnu/packages/ninja.scm | 101 |
1 files changed, 56 insertions, 45 deletions
diff --git a/gnu/packages/ninja.scm b/gnu/packages/ninja.scm index 398c4be10f..c4cd2fd55f 100644 --- a/gnu/packages/ninja.scm +++ b/gnu/packages/ninja.scm @@ -25,61 +25,72 @@ #:use-module ((guix licenses) #:select (asl2.0 expat)) #:use-module (guix gexp) #:use-module (guix packages) + #:use-module (guix utils) #:use-module (guix git-download) #:use-module (guix build-system gnu) #:use-module (guix build-system trivial) #:use-module (guix utils) #:use-module (gnu packages) #:use-module (gnu packages bash) - #:use-module (gnu packages python)) + #:use-module (gnu packages python) + #:use-module (gnu packages re2c) + #:use-module (srfi srfi-1)) -(define-public ninja - (package - (name "ninja") - (version "1.11.1") - (source (origin - (method git-fetch) - (uri (git-reference - (url "https://github.com/ninja-build/ninja") - (commit (string-append "v" version)))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "14kshkxdn833nkz2qkzb3w531dcqj6haad90gxj70ic05lb7zx9f")))) - (build-system gnu-build-system) - (inputs (list python-wrapper)) - (arguments - '(#:phases - (modify-phases %standard-phases - (replace 'configure - (lambda _ - (substitute* "src/subprocess-posix.cc" - (("/bin/sh") (which "sh"))) - (substitute* "src/subprocess_test.cc" - (("/bin/echo") (which "echo"))))) - (replace 'build - (lambda _ - (invoke "./configure.py" "--bootstrap"))) - (replace 'check - (lambda _ - (invoke "./configure.py") - (invoke "./ninja" "ninja_test") - (invoke "./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))))))) - (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 +(define-public ninja/pinned + (hidden-package + (package + (name "ninja") + (version "1.13.1") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/ninja-build/ninja") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0vil4mz0h1z39d2airzdi8cia8xhn3n5p94pv4sd3mqk0pkha40s")))) + (build-system gnu-build-system) + (inputs (list python-wrapper re2c)) + (arguments + '(; Tests now require googletest, which is a circular dependency. + #:tests? #f + #:phases + (modify-phases %standard-phases + (replace 'configure + (lambda _ + (substitute* "src/subprocess-posix.cc" + (("/bin/sh") (which "sh"))) + (substitute* "src/subprocess_test.cc" + (("/bin/echo") (which "echo"))))) + (replace 'build + (lambda _ + (invoke "./configure.py" "--bootstrap"))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "./configure.py") + (invoke "./ninja" "ninja_test") + (invoke "./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))))))) + (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 other build systems in two major respects: it is designed to have its input files generated by a higher-level build system, and it is designed to run builds as fast as possible.") - (license asl2.0))) + (license asl2.0)))) + +(define-public ninja + (package/inherit ninja/pinned + (properties (alist-delete 'hidden? (package-properties ninja/pinned))))) (define-public samurai (package |