[PATCH 0/2] Add s-exp support to Notmuch

  • Done
  • quality assurance status badge
Details
4 participants
  • Christopher Baines
  • Fabio Natali
  • Nicolas Graves
  • Sergio Pastor Pérez
Owner
unassigned
Submitted by
Fabio Natali
Severity
normal
Merged with
F
F
Fabio Natali wrote on 15 Apr 09:19 +0200
(address . guix-patches@gnu.org)(name . Fabio Natali)(address . me@fabionatali.com)
cover.1713165432.git.me@fabionatali.com
Dear All,

On 2022-04-25?, support for S-expression-based queries was added to
Notmuch (version 0.36). This is based on a C/C++ library called sfsexp¹.

You can check whether your Notmuch was built with s-exp support with
this command²:

,----
| notmuch config get built_with.sexp_queries
`----

The Notmuch version currently packaged in Guix does not support s-exp
queries.

This patch micro-series is to:

- Add sfsexp¹.
- Update Notmuch to make use of sfsexp and to allow S-expression-based queries.

Thanks, best wishes, Fabio.




Fabio Natali (2):
gnu: Add sfsexp.
gnu: notmuch: Add sfsexp dependency.

gnu/packages/c.scm | 22 ++++++++++++++++++++++
gnu/packages/mail.scm | 4 +++-
2 files changed, 25 insertions(+), 1 deletion(-)


base-commit: e5dda412c2e28fb65a549824f492895e72c33813
--
2.41.0
F
F
Fabio Natali wrote on 15 Apr 09:25 +0200
[PATCH 1/2] gnu: Add sfsexp.
(address . 70390@debbugs.gnu.org)(name . Fabio Natali)(address . me@fabionatali.com)
139fa7564dab7c3088632370512fcb0d0896da33.1713165432.git.me@fabionatali.com
* gnu/packages/c.scm (sfsexp): New variable.

Change-Id: Iabfbe10b4ad6134ae886a3d26487f881107b559c
---
gnu/packages/c.scm | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)

Toggle diff (35 lines)
diff --git a/gnu/packages/c.scm b/gnu/packages/c.scm
index c004aade73..ef8f9e473b 100644
--- a/gnu/packages/c.scm
+++ b/gnu/packages/c.scm
@@ -628,6 +628,28 @@ (define-public packcc
any other grammar rules.")
(license license:expat)))
+(define-public sfsexp
+ (package
+ (name "sfsexp")
+ (version "1.4.1")
+ (home-page "https://github.com/mjsottile/sfsexp")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url home-page)
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "03srnpc7p1j7ygd0wx9gybcxhqm50kjzkybh1xs75nwz97q3y2dq"))))
+ (build-system gnu-build-system)
+ (native-inputs (list autoconf automake libtool))
+ (synopsis "Symbolic expression library for C and C++")
+ (description
+ "sfsexp is a C/C++ library for the manipulation (read, parse, modify, and create)
+of symbolic expressions.")
+ (license license:lgpl2.1+)))
+
(define-public sparse
(package
(name "sparse")
--
2.41.0
F
F
Fabio Natali wrote on 15 Apr 09:25 +0200
[PATCH 2/2] gnu: notmuch: Add sfsexp dependency.
(address . 70390@debbugs.gnu.org)(name . Fabio Natali)(address . me@fabionatali.com)
5460899548ef69b6c0591be8579faa151090834e.1713165432.git.me@fabionatali.com
sfsexp is a C/C++ library for the manipulation (read, parse, modify, and create)
of symbolic expressions. In an environment where sfsexp is available, Notmuch
will compile with support for a S-expression-based query format. This commit is
to add sfsexp as a Notmuch dependency and therefore to add S-exp support.

Change-Id: Ic3b4a30b2672ad690d66b283e9bdc8e2197f97a7
---
gnu/packages/mail.scm | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)

Toggle diff (31 lines)
diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
index e0fbd0a5ff..2b5561f706 100644
--- a/gnu/packages/mail.scm
+++ b/gnu/packages/mail.scm
@@ -81,6 +81,7 @@ (define-module (gnu packages mail)
#:use-module (gnu packages bash)
#:use-module (gnu packages bison)
#:use-module (gnu packages boost)
+ #:use-module (gnu packages c)
#:use-module (gnu packages calendar)
#:use-module (gnu packages check)
#:use-module (gnu packages compression)
@@ -1414,6 +1415,7 @@ (define-public notmuch
(("/bin/sh") sh))))))))
(native-inputs
(list bash-completion
+ git
pkg-config
python
python-docutils
@@ -1427,7 +1429,7 @@ (define-public notmuch
man-db
perl))
(inputs
- (list glib gmime talloc xapian zlib))
+ (list glib gmime sfsexp talloc xapian zlib))
(home-page "https://notmuchmail.org/")
(synopsis "Thread-based email index, search, and tagging")
(description
--
2.41.0
S
S
Sergio Pastor Pérez wrote on 15 Apr 20:55 +0200
Merging bugs 66547 - 70390
(address . control@debbugs.gnu.org)
PAXP251MB034878097D44A26929796FB1F3092@PAXP251MB0348.EURP251.PROD.OUTLOOK.COM
user guix
merge 66547 70390
quit
N
N
Nicolas Graves wrote on 13 May 10:32 +0200
Re: [bug#70390] [PATCH 2/2] gnu: notmuch: Add sfsexp dependency.
(name . Fabio Natali via Guix-patches via)(address . guix-patches@gnu.org)
87ikziaz86.fsf@ngraves.fr
On 2024-04-15 08:25, Fabio Natali via Guix-patches via wrote:

Toggle quote (28 lines)
> sfsexp is a C/C++ library for the manipulation (read, parse, modify, and create)
> of symbolic expressions. In an environment where sfsexp is available, Notmuch
> will compile with support for a S-expression-based query format. This commit is
> to add sfsexp as a Notmuch dependency and therefore to add S-exp support.
>
> Change-Id: Ic3b4a30b2672ad690d66b283e9bdc8e2197f97a7
> ---
> gnu/packages/mail.scm | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
> index e0fbd0a5ff..2b5561f706 100644
> --- a/gnu/packages/mail.scm
> +++ b/gnu/packages/mail.scm
> @@ -81,6 +81,7 @@ (define-module (gnu packages mail)
> #:use-module (gnu packages bash)
> #:use-module (gnu packages bison)
> #:use-module (gnu packages boost)
> + #:use-module (gnu packages c)
> #:use-module (gnu packages calendar)
> #:use-module (gnu packages check)
> #:use-module (gnu packages compression)
> @@ -1414,6 +1415,7 @@ (define-public notmuch
> (("/bin/sh") sh))))))))
> (native-inputs
> (list bash-completion
> + git

You probably want to use git-minimal here. I've checked that it
builds. Otherwise LGTM.

Toggle quote (13 lines)
> pkg-config
> python
> python-docutils
> @@ -1427,7 +1429,7 @@ (define-public notmuch
> man-db
> perl))
> (inputs
> - (list glib gmime talloc xapian zlib))
> + (list glib gmime sfsexp talloc xapian zlib))
> (home-page "https://notmuchmail.org/")
> (synopsis "Thread-based email index, search, and tagging")
> (description

--
Best regards,
Nicolas Graves
N
N
Nicolas Graves wrote on 13 May 10:38 +0200
(name . Fabio Natali via Guix-patches via)(address . guix-patches@gnu.org)
87cypqayyb.fsf@ngraves.fr
On 2024-04-15 08:25, Fabio Natali via Guix-patches via wrote:

Toggle quote (28 lines)
> sfsexp is a C/C++ library for the manipulation (read, parse, modify, and create)
> of symbolic expressions. In an environment where sfsexp is available, Notmuch
> will compile with support for a S-expression-based query format. This commit is
> to add sfsexp as a Notmuch dependency and therefore to add S-exp support.
>
> Change-Id: Ic3b4a30b2672ad690d66b283e9bdc8e2197f97a7
> ---
> gnu/packages/mail.scm | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
> index e0fbd0a5ff..2b5561f706 100644
> --- a/gnu/packages/mail.scm
> +++ b/gnu/packages/mail.scm
> @@ -81,6 +81,7 @@ (define-module (gnu packages mail)
> #:use-module (gnu packages bash)
> #:use-module (gnu packages bison)
> #:use-module (gnu packages boost)
> + #:use-module (gnu packages c)
> #:use-module (gnu packages calendar)
> #:use-module (gnu packages check)
> #:use-module (gnu packages compression)
> @@ -1414,6 +1415,7 @@ (define-public notmuch
> (("/bin/sh") sh))))))))
> (native-inputs
> (list bash-completion
> + git

Oh and it should also probably be put a few lines down where it's
indicated inputs for tests.

Toggle quote (13 lines)
> pkg-config
> python
> python-docutils
> @@ -1427,7 +1429,7 @@ (define-public notmuch
> man-db
> perl))
> (inputs
> - (list glib gmime talloc xapian zlib))
> + (list glib gmime sfsexp talloc xapian zlib))
> (home-page "https://notmuchmail.org/")
> (synopsis "Thread-based email index, search, and tagging")
> (description

--
Best regards,
Nicolas Graves
N
N
Nicolas Graves wrote on 13 May 10:42 +0200
QA review for 70390
87a5kuayrz.fsf@ngraves.fr
user guix
usertag 70390 + reviewed-looks-good
thanks

Guix QA review form submission:

git should be rewritten to git-minimal and inserted a few lines down instead.
Otherwise LGTM.

Items marked as checked: Lint warnings, Package builds, Commit messages, New package licenses, New package tests, New package synopsis and descriptions

--
Best regards,
Nicolas Graves
N
N
Nicolas Graves wrote on 13 May 10:47 +0200
(address . 70390@debbugs.gnu.org)
877cfyayj7.fsf@ngraves.fr
On 2024-05-13 10:42, Nicolas Graves wrote:

Toggle quote (9 lines)
> user guix
> usertag 70390 + reviewed-looks-good
> thanks
>
> Guix QA review form submission:
>
> git should be rewritten to git-minimal and inserted a few lines down
> instead.

And probably git-minimal/pinned, see https://issues.guix.gnu.org/70656
for instance.

Toggle quote (4 lines)
> Otherwise LGTM.
>
> Items marked as checked: Lint warnings, Package builds, Commit messages, New package licenses, New package tests, New package synopsis and descriptions

--
Best regards,
Nicolas Graves
C
C
Christopher Baines wrote on 13 May 22:43 +0200
Re: [bug#70390] QA review for 70390
(name . Fabio Natali)(address . me@fabionatali.com)
8734ql30ju.fsf@cbaines.net
Nicolas Graves via Guix-patches via <guix-patches@gnu.org> writes:

Toggle quote (18 lines)
> On 2024-05-13 10:42, Nicolas Graves wrote:
>
>> user guix
>> usertag 70390 + reviewed-looks-good
>> thanks
>>
>> Guix QA review form submission:
>>
>> git should be rewritten to git-minimal and inserted a few lines down
>> instead.
>
> And probably git-minimal/pinned, see https://issues.guix.gnu.org/70656
> for instance.
>
>> Otherwise LGTM.
>>
>> Items marked as checked: Lint warnings, Package builds, Commit messages, New package licenses, New package tests, New package synopsis and descriptions

Thanks both, I've tweaked the git input and pushed these patches to
master as b1de64812a0a9e30507fb1ea44611779149c32cc.

Chris
-----BEGIN PGP SIGNATURE-----

iQKlBAEBCgCPFiEEPonu50WOcg2XVOCyXiijOwuE9XcFAmZCe3VfFIAAAAAALgAo
aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF
ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcRHG1haWxAY2Jh
aW5lcy5uZXQACgkQXiijOwuE9XdWaA//fjHP93n0j6RPidUjpm0UmlrACOfV++X/
LJ7YwHVEgdHnK6+QauH+FTgi29miBEKnRPdkGSn5ZBolbNuRqE6XoJjYFq0Iu8wJ
kdYCCHM+9yjfUQ/T8/Kl/ur/iUPiZksmf9KsbEGZRvy51un3QHYDSgqcR2l3WEZn
U/LhBEA5sP6T7uliLPC1VNHzq3WAfQ0k7BDCOdAOInf5lXNIM4wEc8leL2u83VyN
+RhG6TbzGfklfIFo+IG/Z9kNLvZswf6xYUx5zfST+MculZkI6IehjdPQ33h6VIH+
I8B8GSgv1Or2/YvySpu9moXf/0J9RX3NCL7UxfUPFqGozQhiCNYlA3WcDXl17fho
qMoLOrzZ3+jslQeCkFGxPe9toVeKXP/Zeo3iQGSd1RcYhlj0kQqdE0CxVFvUNQxJ
dU5SZDvEXVcC8WV7HOxIBz/SvKWfH9KKV6py0WAWI9tj/mAKKaZABXTinB9PcwWI
F/dLWeTadbIv2/t29RrDDr63Rpqe/KrgFdH1kRcCm2FPDSSfbAZcGuhbCLCn/axH
NBwD9Fz2pnwnVKGUhQLE3zJZqcHp3ZEbkBFLRqvyZEWdiNaHWoOLy+FTZr5RxJU/
t9k7uR3RPpQ7q5shfpSWmrssNUwtK9JHW+4UpM2wfLuVEhbwJ2u6d5uMK5eZqPU3
yPBWz3LzVk4=
=yoFi
-----END PGP SIGNATURE-----

Closed
?
Your comment

This issue is archived.

To comment on this conversation send an email to 70390@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 70390
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch