[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug#54216] [PATCH shepherd staging v2] gnu: shepherd: Build it from git
From: |
Attila Lendvai |
Subject: |
[bug#54216] [PATCH shepherd staging v2] gnu: shepherd: Build it from git, and clean up shepherd-for-guix. |
Date: |
Fri, 4 Mar 2022 11:30:29 +0100 |
* gnu/packages/admin.scm (shepherd): Change SOURCE to point to the git
repository.
(shepherd-for-guix): Simplify by moving most of the customizations into the
above.
---
i accidentally used the wrong hash in the first version. v2 fixes it, and
also adds a more conformant commit message.
my server is now building/reconfiguring into this codebase, that's how i've
noticed my mistake. no idea why it didn't surface earlier, probably due
to an unfortunate ordering of the test builds and the copy-paste mistake.
gnu/packages/admin.scm | 70 +++++++++++++++++-------------------------
1 file changed, 28 insertions(+), 42 deletions(-)
diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm
index dbceaca5e5..882dc9f121 100644
--- a/gnu/packages/admin.scm
+++ b/gnu/packages/admin.scm
@@ -270,26 +270,31 @@ (define-public shepherd
(package
(name "shepherd")
(version "0.8.1")
- (source (origin
- (method url-fetch)
- (uri (string-append "mirror://gnu/shepherd/shepherd-"
- version ".tar.gz"))
- (sha256
- (base32
- "0x9zr0x3xvk4qkb6jnda451d5iyrl06cz1bjzjsm0lxvjj3fabyk"))
- (modules '((guix build utils)))
- (snippet
- '(begin
- ;; Build with -O1 to work around
<https://bugs.gnu.org/48368>.
- (substitute* "Makefile.in"
- (("compile --target")
- "compile -O1 --target"))))))
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://git.savannah.gnu.org/git/shepherd.git/")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "109ha9rk4ycqcmx9cddlbym92c3fvbwp12q9p42h8sg8vr367w5j"))
+ (modules '((guix build utils)))))
(build-system gnu-build-system)
(arguments
'(#:configure-flags '("--localstatedir=/var")
- #:make-flags '("GUILE_AUTO_COMPILE=0")))
+ #:make-flags '("GUILE_AUTO_COMPILE=0")
+ #:phases
+ (modify-phases %standard-phases
+ ;; TODO delete this once Guile is updated to v3.0.8+
+ (add-after 'unpack 'patch-source
+ (lambda _
+ ;; Build with -O1 to work around <https://bugs.gnu.org/48368>.
+ (substitute* "Makefile.am"
+ (("compile --target")
+ "compile -O1 --target")))))))
(native-inputs
- (list pkg-config
+ (list autoconf automake gettext-minimal help2man texinfo pkg-config
;; This is the Guile we use as a cross-compiler...
guile-3.0))
(inputs
@@ -314,45 +319,26 @@ (define-public shepherd
;; [TODO] in the manual.
(define-public shepherd-for-guix
(let* ((version "0.8.1")
- ;; If it's an unreleased commit:
+ ;; A commit string, or #f if it's a release.
(commit "7c380590164ea8ee40de46059d07e08a48963577")
- ;; Use the below form if it's a release, and also set REVISION to #f.
- ;; (commit (string-append "v" version))
- (revision "1"))
+ (revision "1") ; Only relevant when COMMIT is specified.
+ (git-ref (or commit (string-append "v" version))))
(package
(inherit shepherd)
- (version (if revision
+ (version (if commit
(git-version version revision commit)
version))
(source
(origin
(inherit (package-source shepherd))
- (method git-fetch)
(uri (git-reference
;; Build from git and add Autotools inputs, to make developing
;; Shepherd easier. It enables easier package inheritance.
(url "https://git.savannah.gnu.org/git/shepherd.git/")
- (commit commit)))
- (snippet #f) ; TODO delete this once parent is refactored.
+ (commit git-ref)))
(sha256
- (base32
- "1hgkbl3fyzwi5vw63kbkswnf3viyfl52c5dzkx7vbkr4sj5ysz1g"))))
- ;; TODO merge this back into the parent with a patch to staging.
- (arguments
- (append
- (package-arguments shepherd)
- '(#:phases
- (modify-phases %standard-phases
- (add-after 'unpack 'patch-source
- (lambda _
- ;; Build with -O1 to work around <https://bugs.gnu.org/48368>.
- (substitute* "Makefile.am"
- (("compile --target")
- "compile -O1 --target"))))))))
- (native-inputs
- (modify-inputs (package-native-inputs shepherd)
- (prepend autoconf automake gettext-minimal help2man texinfo)))
- (description "A package variant for use in Guix. It helps lowering
+ (base32 "1hgkbl3fyzwi5vw63kbkswnf3viyfl52c5dzkx7vbkr4sj5ysz1g"))))
+ (description "A package variant for use in Guix. It helps lowering
the build time of Guix when working on Shepherd."))))
(define-public guile2.2-shepherd
--
2.34.0
- [bug#54216] [PATCH v2] gnu: shepherd-for-guix: New package for use in Guix., (continued)
- [bug#54216] [PATCH v2] gnu: shepherd-for-guix: New package for use in Guix., zimoun, 2022/03/02
- [bug#54216] [PATCH v2] gnu: shepherd-for-guix: New package for use in Guix., Leo Famulari, 2022/03/02
- [bug#54216] [PATCH v2] gnu: shepherd-for-guix: New package for use in Guix., Maxime Devos, 2022/03/03
- [bug#54216] [PATCH v2] gnu: shepherd-for-guix: New package for use in Guix., zimoun, 2022/03/03
- [bug#54216] [PATCH v2] gnu: shepherd-for-guix: New package for use in Guix., Leo Famulari, 2022/03/05
- [bug#54216] [PATCH v2] gnu: shepherd-for-guix: New package for use in Guix., Maxime Devos, 2022/03/05
- [bug#54216] [PATCH staging] gnu: shepherd: Build it from git, and clean up shepherd-for-guix., Maxime Devos, 2022/03/03
- [bug#54216] [PATCH staging] gnu: shepherd: Build it from git, and clean up shepherd-for-guix., zimoun, 2022/03/03
[bug#54216] [PATCH v3] gnu: shepherd-for-guix: New package for use in Guix., Attila Lendvai, 2022/03/03
[bug#54216] [PATCH staging] gnu: shepherd: Build it from git, and clean up shepherd-for-guix., Attila Lendvai, 2022/03/03
[bug#54216] [PATCH shepherd staging v2] gnu: shepherd: Build it from git, and clean up shepherd-for-guix.,
Attila Lendvai <=
[bug#54216] [PATCH v4] gnu: shepherd-for-guix: New package for use in Guix., Attila Lendvai, 2022/03/21
[bug#54216] [PATCH staging v3] gnu: shepherd: Build it from git, and clean up shepherd-for-guix., Attila Lendvai, 2022/03/21