diff --git a/srcpkgs/notmuch/notmuch-python3.INSTALL.msg b/srcpkgs/notmuch/notmuch-python3.INSTALL.msg new file mode 100644 index 00000000000..5e36b54b501 --- /dev/null +++ b/srcpkgs/notmuch/notmuch-python3.INSTALL.msg @@ -0,0 +1,3 @@ +The legacy python bindings in this package have been deprecated and +are unsupported by notmuch, and will likely be phased out in upcoming +releases. Please switch to the new cffi bindings in python3-notmuch2. diff --git a/srcpkgs/notmuch/template b/srcpkgs/notmuch/template index 52648d3305d..d35db7d9b30 100644 --- a/srcpkgs/notmuch/template +++ b/srcpkgs/notmuch/template @@ -1,14 +1,15 @@ # Template file for 'notmuch' pkgname=notmuch -version=0.38 -revision=4 +version=0.39 +revision=1 build_style=configure build_helper=python3 configure_args="--prefix=/usr --emacslispdir=/usr/share/emacs/site-lisp/notmuch --emacsetcdir=/usr/share/emacs/site-lisp/notmuch" hostmakedepends="perl pkg-config python3-Sphinx python3-devel texinfo - desktop-file-utils emacs gnupg python3-setuptools python3-cffi" + desktop-file-utils emacs gnupg python3-setuptools python3-cffi + python3-build python3-installer doxygen" makedepends="bash-completion gmime3-devel talloc-devel xapian-core-devel python3-cffi" depends="gmime3>=3.2.7" @@ -20,11 +21,13 @@ license="GPL-3.0-or-later" homepage="https://notmuchmail.org" distfiles="https://notmuchmail.org/releases/notmuch-${version}.tar.xz https://notmuchmail.org/releases/test-databases/database-v1.tar.xz" -checksum="a17901adbe43f481a6bf53c15a2a20268bc8dc7ad5ccf685a0d17c1456dbaf6e +checksum="b88bb02a76c46bad8d313fd2bb4f8e39298b51f66fcbeb304d9f80c3eef704e3 4299e051b10e1fa7b33ea2862790a09ebfe96859681804e5251e130f800e69d2" skip_extraction="database-v1.tar.xz" replaces="notmuch-emacs>=0" +make_check="ci-skip" # dtach based tests fail in CI due to no pty + # Not a real conflicts, but this package is broken with gpgme 1.13.1- # gpgme is optional dependency conflicts="gpgme<1.14.0_1" @@ -39,10 +42,10 @@ fi do_build() { make ${makejobs} make -C contrib/notmuch-mutt - cd ${wrksrc}/bindings/python - python3 setup.py build --build-base=build cd ${wrksrc}/bindings/python-cffi - python3 setup.py build --build-base=build + python -m build --wheel --skip-dependency-check --no-isolation + cd ${wrksrc}/contrib/python-legacy + python -m build --wheel --skip-dependency-check --no-isolation } do_check() { @@ -51,17 +54,20 @@ do_check() { # Seem like gpgconf's problem, # mutt on musl also have problems with smime NOTMUCH_SKIP_TESTS="smime.3 smime.5" + # bad regex test fails on musl + NOTMUCH_SKIP_TESTS+=" as-text.10" else # This test run under gdb is problematic NOTMUCH_SKIP_TESTS="count.14" fi # libconfig because of fqdn - # we don't ship python-cffi - NOTMUCH_SKIP_TESTS+=" libconfig python-cffi" + NOTMUCH_SKIP_TESTS+=" libconfig" NOTMUCH_SKIP_TESTS+=" crypto index-decryption" if [ $(id -u) = 0 ]; then NOTMUCH_SKIP_TESTS+=" new.36 new.39 tagging.25" fi + # fails due to our gmime configure patches + NOTMUCH_SKIP_TESTS+=" smime.4" export NOTMUCH_SKIP_TESTS make test } @@ -84,6 +90,7 @@ libnotmuch-devel_package() { pkg_install() { vmove usr/include vmove usr/lib/*.so + vmove usr/share/man/man3 } } @@ -99,21 +106,19 @@ notmuch-mutt_package() { notmuch-python3_package() { depends="libnotmuch python3" - short_desc+=" - Python 3 bindings" + short_desc+=" - Python 3 bindings (legacy)" pkg_install() { - cd ${wrksrc}/bindings/python - python3 setup.py build --build-base=build \ - install --prefix=/usr --root=${PKGDESTDIR} + cd ${wrksrc}/contrib/python-legacy + python -m installer --destdir="$PKGDESTDIR" dist/*.whl } } python3-notmuch2_package() { - depends="libnotmuch python3" + depends="libnotmuch python3 python3-cffi" short_desc+=" - Python 3 cffi bindings" pkg_install() { cd ${wrksrc}/bindings/python-cffi - python3 setup.py build --build-base=build \ - install --prefix=/usr --root=${PKGDESTDIR} + python -m installer --destdir="$PKGDESTDIR" dist/*.whl } }