[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 5/6] gnu: Add borg.
From: |
Alex Kost |
Subject: |
Re: [PATCH 5/6] gnu: Add borg. |
Date: |
Tue, 15 Mar 2016 12:11:15 +0300 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) |
Leo Famulari (2016-03-15 02:34 +0300) wrote:
> * gnu/packages/backup.scm (borg): New variable.
> ---
> gnu/packages/backup.scm | 53
> ++++++++++++++++++++++++++++++++++++++++++++++++-
> 1 file changed, 52 insertions(+), 1 deletion(-)
[...]
> +(define-public borg
> + (package
> + (name "borg")
> + (version "1.0.0")
> + (source (origin
> + (method url-fetch)
> + (uri (pypi-uri "borgbackup" version))
> + (sha256
> + (base32
> + "0wa6cvqs3rni5nwrgagigchcly8a53rxk56z0zn8iaii2cqrw2sh"))))
> + (build-system python-build-system)
> + (arguments
> + `(#:phases
> + (modify-phases %standard-phases
> + (add-before 'build 'set-openssl-prefix
> + (lambda* (#:key inputs #:allow-other-keys)
> + (setenv "BORG_OPENSSL_PREFIX" (assoc-ref inputs "openssl"))
> + #t))
> + (add-before 'build 'set-lz4-prefix
> + (lambda* (#:key inputs #:allow-other-keys)
> + (setenv "BORG_LZ4_PREFIX" (assoc-ref inputs "lz4"))
> + #t))
Would it be better to make a single 'set-env' phase instead? Or better
yet, are these '..._PREFIX' variables used for make command? If so,
they should be specified in #:make-flags argument.
> + (add-after 'install 'docs
> + (lambda* (#:key outputs #:allow-other-keys)
> + (let* ((out (assoc-ref outputs "out"))
> + (man (string-append out "/share/man/man1")))
> + (and
> + (zero? (system* "make" "-C" "docs" "man"))
> + (install-file "docs/_build/man/borg.1" man)))
Since 'install-file' does not specify a returned value, and we are not
really interested in the returned value, I think it is better to use
'when' instead of 'and' here:
(when (zero? (system* "make" "-C" "docs" "man"))
(install-file "docs/_build/man/borg.1" man))
> + #t)))))
--
Alex
- Re: [PATCH 4/6] gnu: python-llfuse: Update to 1.0, keep 0.41 variant., (continued)
- Re: [PATCH 4/6] gnu: python-llfuse: Update to 1.0, keep 0.41 variant., Alex Kost, 2016/03/15
- Re: [PATCH 4/6] gnu: python-llfuse: Update to 1.0, keep 0.41 variant., Leo Famulari, 2016/03/15
- Re: [PATCH 4/6] gnu: python-llfuse: Update to 1.0, keep 0.41 variant., Mathieu Lirzin, 2016/03/15
- Re: [PATCH 4/6] gnu: python-llfuse: Update to 1.0, keep 0.41 variant., Ludovic Courtès, 2016/03/15
- Re: [PATCH 4/6] gnu: python-llfuse: Update to 1.0, keep 0.41 variant., Leo Famulari, 2016/03/20
- Re: [PATCH 4/6] gnu: python-llfuse: Update to 1.0, keep 0.41 variant., Alex Kost, 2016/03/21
[PATCH 3/6] gnu: attic: Specify dependency on address@hidden, Leo Famulari, 2016/03/14
[PATCH 5/6] gnu: Add borg., Leo Famulari, 2016/03/14
- Re: [PATCH 5/6] gnu: Add borg.,
Alex Kost <=
- Re: [PATCH 5/6] gnu: Add borg., Leo Famulari, 2016/03/15
- Re: [PATCH 5/6] gnu: Add borg., Leo Famulari, 2016/03/21
- Re: [PATCH 5/6] gnu: Add borg., Leo Famulari, 2016/03/21
- Re: [PATCH 5/6] gnu: Add borg., Leo Famulari, 2016/03/21
- Re: [PATCH 5/6] gnu: Add borg., Alex Kost, 2016/03/22
- Re: [PATCH 5/6] gnu: Add borg., Leo Famulari, 2016/03/22
- Re: [PATCH 5/6] gnu: Add borg., Alex Kost, 2016/03/23
- Re: [PATCH 5/6] gnu: Add borg., Efraim Flashner, 2016/03/23
[PATCH 6/6] gnu: address@hidden: Update to 0.41.1., Leo Famulari, 2016/03/14
[PATCH 2/6] gnu: python-msgpack: Use 'python2-variant'., Leo Famulari, 2016/03/14