summaryrefslogtreecommitdiff
path: root/gnu/packages/mail.scm
diff options
context:
space:
mode:
authorLiliana Marie Prikler <liliana.prikler@gmail.com>2022-03-23 21:12:38 +0100
committerLiliana Marie Prikler <liliana.prikler@gmail.com>2022-03-23 21:12:38 +0100
commit7258c90572588341abc22b4edabd2dbf33a6f718 (patch)
tree792e4b10ef2bdfdb251a305e6a3707f81576f8f9 /gnu/packages/mail.scm
parent8d33d7b42f0c676beebfa38bd45e682f6958c17f (diff)
gnu: python-notmuch2: Use new style.
* gnu/packages/mail.scm (python-notmuch2)[version]: Explicitly inherit from notmuch. [arguments]: Use list of G-Expressions.
Diffstat (limited to 'gnu/packages/mail.scm')
-rw-r--r--gnu/packages/mail.scm54
1 files changed, 28 insertions, 26 deletions
diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
index 6380412330..ee5e576a18 100644
--- a/gnu/packages/mail.scm
+++ b/gnu/packages/mail.scm
@@ -1486,34 +1486,36 @@ and search library.")
(package
(inherit python-notmuch)
(name "python-notmuch2")
+ (version (package-version notmuch))
(propagated-inputs (list python-cffi))
(arguments
- `(#:phases
- (modify-phases %standard-phases
- ;; This python package lives in a subdirectory of the notmuch source
- ;; tree, so chdir into it before building.
- (add-after 'unpack 'enter-python-dir
- (lambda _ (chdir "bindings/python-cffi")))
- ;; python-build-system does not invoke the configure script
- ;; so _notmuch_config.py is missing
- (add-after 'enter-python-dir 'create-notmuch-config
- (lambda* (#:key inputs #:allow-other-keys)
- (with-output-to-file "_notmuch_config.py"
- (lambda _
- (display
- (string-append
- "NOTMUCH_INCLUDE_DIR="
- "'" (dirname (search-input-file inputs "include/notmuch.h")) "'\n"
- "NOTMUCH_LIB_DIR="
- "'" (dirname (search-input-file inputs "lib/libnotmuch.so")) "'"))))))
- ;; version.txt is not included in notmuch, so we patch in the version number
- (add-after 'create-notmuch-config 'patch-setup.py
- (lambda _
- (substitute* "setup.py"
- (("NOTMUCH_VERSION_FILE")
- "'/dev/null'")
- (("version=VERSION,")
- (string-append "version='" ,(package-version this-package) "',"))))))))
+ (list
+ #:phases
+ #~(modify-phases %standard-phases
+ ;; This python package lives in a subdirectory of the notmuch source
+ ;; tree, so chdir into it before building.
+ (add-after 'unpack 'enter-python-dir
+ (lambda _ (chdir "bindings/python-cffi")))
+ ;; python-build-system does not invoke the configure script
+ ;; so _notmuch_config.py is missing
+ (add-after 'enter-python-dir 'create-notmuch-config
+ (lambda* (#:key inputs #:allow-other-keys)
+ (with-output-to-file "_notmuch_config.py"
+ (lambda _
+ (display
+ (string-append
+ "NOTMUCH_INCLUDE_DIR="
+ "'" (dirname (search-input-file inputs "include/notmuch.h")) "'\n"
+ "NOTMUCH_LIB_DIR="
+ "'" (dirname (search-input-file inputs "lib/libnotmuch.so")) "'"))))))
+ ;; version.txt is not included in notmuch, so we patch in the version number
+ (add-after 'create-notmuch-config 'patch-setup.py
+ (lambda _
+ (substitute* "setup.py"
+ (("NOTMUCH_VERSION_FILE")
+ "'/dev/null'")
+ (("version=VERSION,")
+ (string-append "version='" #$version "',"))))))))
(synopsis "Pythonic bindings for the notmuch mail database using CFFI")
(license license:gpl3+)))