gnu: ccache: Update to 4.2.
* gnu/packages/ccache.scm (ccache): Update to 4.2. [build-system]: Switch to cmake-build-system. [inputs]: Add zstd:lib. [arguments]: Move substitution before change of directory and add phase to set HOME variable. Signed-off-by: Efraim Flashner <efraim@flashner.co.il>master
parent
da80d4e6a7
commit
3f944e6204
|
@ -2,6 +2,7 @@
|
||||||
;;; Copyright © 2014, 2015, 2016, 2018 Eric Bavier <bavier@member.fsf.org>
|
;;; Copyright © 2014, 2015, 2016, 2018 Eric Bavier <bavier@member.fsf.org>
|
||||||
;;; Copyright © 2016, 2017 Efraim Flashner <efraim@flashner.co.il>
|
;;; Copyright © 2016, 2017 Efraim Flashner <efraim@flashner.co.il>
|
||||||
;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
|
;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
|
||||||
|
;;; Copyright © 2021 Greg Hogan <code@greghogan.com>
|
||||||
;;;
|
;;;
|
||||||
;;; This file is part of GNU Guix.
|
;;; This file is part of GNU Guix.
|
||||||
;;;
|
;;;
|
||||||
|
@ -22,7 +23,7 @@
|
||||||
#:use-module (guix packages)
|
#:use-module (guix packages)
|
||||||
#:use-module ((guix licenses) #:select (gpl3+))
|
#:use-module ((guix licenses) #:select (gpl3+))
|
||||||
#:use-module (guix download)
|
#:use-module (guix download)
|
||||||
#:use-module (guix build-system gnu)
|
#:use-module (guix build-system cmake)
|
||||||
#:use-module (gnu packages)
|
#:use-module (gnu packages)
|
||||||
#:use-module (gnu packages perl)
|
#:use-module (gnu packages perl)
|
||||||
#:use-module (gnu packages compression))
|
#:use-module (gnu packages compression))
|
||||||
|
@ -30,25 +31,32 @@
|
||||||
(define-public ccache
|
(define-public ccache
|
||||||
(package
|
(package
|
||||||
(name "ccache")
|
(name "ccache")
|
||||||
(version "3.7.12")
|
(version "4.2")
|
||||||
(source
|
(source
|
||||||
(origin
|
(origin
|
||||||
(method url-fetch)
|
(method url-fetch)
|
||||||
(uri (string-append "https://github.com/ccache/ccache/releases/download/v"
|
(uri (string-append "https://github.com/ccache/ccache/releases/download/v"
|
||||||
version "/ccache-" version ".tar.xz"))
|
version "/ccache-" version ".tar.xz"))
|
||||||
(sha256
|
(sha256
|
||||||
(base32 "005liq8csgxdn7m9hj2ah07hishww855p8sc96y1hrnwc21lwbx0"))))
|
(base32 "0kx9ggbbm899zwyyxvm4dgzn1b95zi1niz0l734pi5y3i0cb251g"))))
|
||||||
(build-system gnu-build-system)
|
(build-system cmake-build-system)
|
||||||
(native-inputs `(("perl" ,perl) ; for test/run
|
(native-inputs `(("perl" ,perl) ; for test/run
|
||||||
("which" ,(@ (gnu packages base) which))))
|
("which" ,(@ (gnu packages base) which))))
|
||||||
(inputs `(("zlib" ,zlib)))
|
(inputs `(("zlib" ,zlib)
|
||||||
|
("zstd" ,zstd "lib")))
|
||||||
(arguments
|
(arguments
|
||||||
'(#:phases (modify-phases %standard-phases
|
'(#:phases
|
||||||
(add-before 'check 'setup-tests
|
(modify-phases %standard-phases
|
||||||
(lambda _
|
(add-before 'configure 'setup-tests
|
||||||
(substitute* '("unittest/test_hashutil.c" "test/suites/base.bash")
|
(lambda _
|
||||||
(("#!/bin/sh") (string-append "#!" (which "sh"))))
|
(substitute* '("unittest/test_hashutil.cpp" "test/suites/base.bash")
|
||||||
#t)))))
|
(("#!/bin/sh") (string-append "#!" (which "sh"))))
|
||||||
|
#t))
|
||||||
|
;; tests require a writable HOME
|
||||||
|
(add-before 'check 'set-home
|
||||||
|
(lambda _
|
||||||
|
(setenv "HOME" (getenv "TMPDIR"))
|
||||||
|
#t)))))
|
||||||
(home-page "https://ccache.dev/")
|
(home-page "https://ccache.dev/")
|
||||||
(synopsis "Compiler cache")
|
(synopsis "Compiler cache")
|
||||||
(description
|
(description
|
||||||
|
|
Reference in New Issue