From 75b7082bdf1ef1de9d4e2a0786120f051e7fffbd Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Wed, 18 Jan 2023 11:55:51 +0100 Subject: gnu: guile-next: Add '.tarball-version' file to get correct version. So far, "guile --version" and 'guile-3.0.pc' would use "UNKNOWN" as the version string, making the package unsuitable as a drop-in replacement for the 'guile-3.0' package. * gnu/packages/guile.scm (guile-next)[arguments]: Add 'set-version' phase. --- gnu/packages/guile.scm | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'gnu/packages') diff --git a/gnu/packages/guile.scm b/gnu/packages/guile.scm index a0ed572cc0..9148c1075a 100644 --- a/gnu/packages/guile.scm +++ b/gnu/packages/guile.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012-2022 Ludovic Courtès +;;; Copyright © 2012-2023 Ludovic Courtès ;;; Copyright © 2014 Cyril Roelandt ;;; Copyright © 2014, 2016, 2018 David Thompson ;;; Copyright © 2014, 2017, 2018 Mark H Weaver @@ -453,6 +453,16 @@ (define-public guile-next (substitute-keyword-arguments (package-arguments guile-3.0) ((#:phases phases '%standard-phases) `(modify-phases ,phases + (add-before 'bootstrap 'set-version + (lambda _ + ;; Tell 'git-version-gen' what version this is, or it will + ;; just pick "UNKNOWN", making it unusable as a replacement + ;; for 'guile-3.0'. XXX: This is inaccurate when using + ;; '--with-branch' but using (package-version this-package) + ;; wouldn't give us a valid version string. + (call-with-output-file ".tarball-version" + (lambda (port) + (display ,version port))))) (add-before 'check 'skip-failing-tests (lambda _ (substitute* "test-suite/standalone/test-out-of-memory" -- cgit v1.2.3