diff --git a/gnu/packages/backup.scm b/gnu/packages/backup.scm index 5aa0d5688f..49b0fe2620 100644 --- a/gnu/packages/backup.scm +++ b/gnu/packages/backup.scm @@ -116,22 +116,20 @@ (define-public duplicity (base32 "14x5brpq1l400i9l2hnyqmbn19cc1hnbmj5fn8cs8zzwzbgrfxng")))) (build-system python-build-system) (native-inputs - `(("gettext" ,gettext-minimal) ; for msgfmt - ("util-linux" ,util-linux) ; setsid command, for the tests - ("par2cmdline" ,par2cmdline) - ("python-fasteners" ,python-fasteners) - ("python-future" ,python-future) ; for tests - ("python-paramiko" ,python-paramiko) - ("python-pexpect" ,python-pexpect) - ("python-pytest" ,python-pytest) - ("python-pytest-runner" ,python-pytest-runner) - ("python-setuptools-scm" ,python-setuptools-scm) - ("tzdata" ,tzdata-for-tests) - ("mock" ,python-mock))) + (list gettext-minimal ; for msgfmt + util-linux ; setsid command, for the tests + par2cmdline + python-fasteners + python-future ; for tests + python-paramiko + python-pexpect + python-pytest + python-pytest-runner + python-setuptools-scm + tzdata-for-tests + python-mock)) (propagated-inputs - `(("lockfile" ,python-lockfile) - ("pygobject" ,python-pygobject) - ("urllib3" ,python-urllib3))) + (list python-lockfile python-pygobject python-urllib3)) (inputs (list dbus ; dbus-launch (Gio backend) librsync @@ -139,36 +137,41 @@ (define-public duplicity gnupg ; gpg executable needed util-linux)) ; for setsid (arguments - `(#:test-target "test" - #:phases - (modify-phases %standard-phases - (add-before 'build 'use-store-file-names - (lambda* (#:key inputs #:allow-other-keys) - (substitute* "duplicity/gpginterface.py" - (("self.call = u'gpg'") - (string-append "self.call = '" - (search-input-file inputs "/bin/gpg") - "'"))) - (substitute* "duplicity/backends/giobackend.py" - (("subprocess.Popen\\(\\[u'dbus-launch'\\]") - (string-append "subprocess.Popen([u'" - (search-input-file inputs "/bin/dbus-launch") - "']"))) - (substitute* '("testing/functional/__init__.py" - "testing/overrides/bin/lftp") - (("/bin/sh") (which "sh"))))) - (add-before 'build 'fix-version - (lambda _ - (substitute* "duplicity/__init__.py" - (("\\$version") ,(package-version this-package))))) - (add-before 'check 'set-up-tests - (lambda* (#:key inputs #:allow-other-keys) - (setenv "HOME" (getcwd)) ; gpg needs to write to $HOME - (setenv "TZDIR" ; some timestamp checks need TZDIR - (search-input-directory inputs "share/zoneinfo")) - ;; Some things respect TMPDIR, others hard-code /tmp, and the - ;; defaults don't match up, breaking test_restart. Fix it. - (setenv "TMPDIR" "/tmp")))))) + (list #:test-target "test" + #:phases + #~(modify-phases %standard-phases + (add-before 'build 'use-store-file-names + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "duplicity/gpginterface.py" + (("self.call = u'gpg'") + (string-append "self.call = '" + (search-input-file inputs + "/bin/gpg") + "'"))) + (substitute* "duplicity/backends/giobackend.py" + (("subprocess.Popen\\(\\[u'dbus-launch'\\]") + (string-append "subprocess.Popen([u'" + (search-input-file inputs + "/bin/dbus-launch") "']"))) + (substitute* '("testing/functional/__init__.py" + "testing/overrides/bin/lftp") + (("/bin/sh") + (which "sh"))))) + (add-before 'build 'fix-version + (lambda _ + (substitute* "duplicity/__init__.py" + (("\\$version") + #$(package-version this-package))))) + (add-before 'check 'set-up-tests + (lambda* (#:key inputs #:allow-other-keys) + (setenv "HOME" + (getcwd)) ; gpg needs to write to $HOME + (setenv "TZDIR" ; some timestamp checks need TZDIR + (search-input-directory inputs + "share/zoneinfo")) + ;; Some things respect TMPDIR, others hard-code /tmp, and the + ;; defaults don't match up, breaking test_restart. Fix it. + (setenv "TMPDIR" "/tmp")))))) (home-page "https://duplicity.gitlab.io/duplicity-web/") (synopsis "Encrypted backup using rsync algorithm") (description