New diff with suggestions from kmos.
On Thu, 07 Nov 2019, Paco Esteban wrote:
> Hi ports@,
>
> Here's an update for productivity/khard from 0.13.0 to 0.15.1.
>
> The changelog:
>
> ...
>
> I have question regarding the new man pages generation. They use
> a (gnu)make target with some variables pointing to sphinx executables.
> On OpenBSD those executables are called differently (they have the
> python flavor at the end). I resolved that just passing the variables
> to gmake with the correct path of those files, is that the correct way
> to do it ? Do you suggest any other approach ?
Still have doubts on how to do this right. Comments welcome.
And now the diff:
Index: Makefile
===================================================================
RCS file: /cvs/ports/productivity/khard/Makefile,v
retrieving revision 1.3
diff -u -p -r1.3 Makefile
--- Makefile 5 Jun 2019 11:21:56 -0000 1.3
+++ Makefile 7 Nov 2019 21:57:58 -0000
@@ -2,7 +2,7 @@
COMMENT = console CardDAV client
-MODPY_EGG_VERSION = 0.13.0
+MODPY_EGG_VERSION = 0.15.1
DISTNAME = khard-${MODPY_EGG_VERSION}
CATEGORIES = productivity
@@ -18,7 +18,12 @@ MODULES = lang/python
MODPY_PI = Yes
MODPY_SETUPTOOLS = Yes
MODPY_VERSION = ${MODPY_DEFAULT_VERSION_3}
-MODPY_TEST = Yes
+MODPY_PYTEST = Yes
+
+BUILD_DEPENDS = devel/gmake \
+ devel/py-setuptools_scm${MODPY_FLAVOR} \
+ textproc/py-sphinx${MODPY_FLAVOR} \
+ ${RUN_DEPENDS}
RUN_DEPENDS = devel/py-atomicwrites${MODPY_FLAVOR} \
devel/py-configobj${MODPY_FLAVOR} \
@@ -26,6 +31,12 @@ RUN_DEPENDS = devel/py-atomicwrites${MO
textproc/py-unidecode${MODPY_FLAVOR} \
textproc/py-vobject${MODPY_FLAVOR}
+post-build:
+ @cd ${WRKSRC} && \
+ gmake -C doc man \
+ SPHINXAPIDOC=/usr/local/bin/sphinx-apidoc-3 \
+ SPHINXBUILD=/usr/local/bin/sphinx-build-3
+
post-install:
${INSTALL_DATA_DIR} ${PREFIX}/share/examples/khard
${INSTALL_DATA} ${WRKSRC}/misc/khard/khard.conf.example \
@@ -33,5 +44,11 @@ post-install:
${INSTALL_DATA_DIR} ${PREFIX}/share/zsh/vendor-completions
${INSTALL_DATA} ${WRKSRC}/misc/zsh/{_khard,_email-khard} \
${PREFIX}/share/zsh/vendor-completions
+ ${INSTALL_DATA_DIR} ${PREFIX}/man/man1
+ ${INSTALL_DATA} ${WRKSRC}/doc/build/man/khard.1 \
+ ${PREFIX}/man/man1
+ ${INSTALL_DATA_DIR} ${PREFIX}/man/man5
+ ${INSTALL_DATA} ${WRKSRC}/doc/build/man/khard.conf.5 \
+ ${PREFIX}/man/man5
.include <bsd.port.mk>
Index: distinfo
===================================================================
RCS file: /cvs/ports/productivity/khard/distinfo,v
retrieving revision 1.2
diff -u -p -r1.2 distinfo
--- distinfo 5 Jun 2019 11:21:56 -0000 1.2
+++ distinfo 7 Nov 2019 21:57:58 -0000
@@ -1,2 +1,2 @@
-SHA256 (khard-0.13.0.tar.gz) = /JPQuR9+aIqPYIlrT/exlo1rTLWNgPypl3Iyw6aO0tM=
-SIZE (khard-0.13.0.tar.gz) = 5083020
+SHA256 (khard-0.15.1.tar.gz) = XKjmeBM+CPpIYcwxrt+fMLT445WO1m7eAlwj7F4XaqE=
+SIZE (khard-0.15.1.tar.gz) = 5099734
Index: pkg/PLIST
===================================================================
RCS file: /cvs/ports/productivity/khard/pkg/PLIST,v
retrieving revision 1.2
diff -u -p -r1.2 PLIST
--- pkg/PLIST 5 Jun 2019 11:21:56 -0000 1.2
+++ pkg/PLIST 7 Nov 2019 21:57:58 -0000
@@ -1,5 +1,7 @@
@comment $OpenBSD: PLIST,v 1.2 2019/06/05 11:21:56 sthen Exp $
bin/khard
+lib/python${MODPY_VERSION}/
+lib/python${MODPY_VERSION}/site-packages/
lib/python${MODPY_VERSION}/site-packages/khard/
lib/python${MODPY_VERSION}/site-packages/khard-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/
lib/python${MODPY_VERSION}/site-packages/khard-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/PKG-INFO
@@ -16,6 +18,7 @@ lib/python${MODPY_VERSION}/site-packages
lib/python${MODPY_VERSION}/site-packages/khard/${MODPY_PYCACHE}actions.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/khard/${MODPY_PYCACHE}address_book.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/khard/${MODPY_PYCACHE}carddav_object.${MODPY_PYC_MAGIC_TAG}pyc
+lib/python${MODPY_VERSION}/site-packages/khard/${MODPY_PYCACHE}cli.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/khard/${MODPY_PYCACHE}config.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/khard/${MODPY_PYCACHE}helpers.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/khard/${MODPY_PYCACHE}khard.${MODPY_PYC_MAGIC_TAG}pyc
@@ -24,11 +27,17 @@ lib/python${MODPY_VERSION}/site-packages
lib/python${MODPY_VERSION}/site-packages/khard/actions.py
lib/python${MODPY_VERSION}/site-packages/khard/address_book.py
lib/python${MODPY_VERSION}/site-packages/khard/carddav_object.py
+lib/python${MODPY_VERSION}/site-packages/khard/cli.py
lib/python${MODPY_VERSION}/site-packages/khard/config.py
+lib/python${MODPY_VERSION}/site-packages/khard/data/
+lib/python${MODPY_VERSION}/site-packages/khard/data/config.spec
+lib/python${MODPY_VERSION}/site-packages/khard/data/template.yaml
lib/python${MODPY_VERSION}/site-packages/khard/helpers.py
lib/python${MODPY_VERSION}/site-packages/khard/khard.py
lib/python${MODPY_VERSION}/site-packages/khard/object_type.py
lib/python${MODPY_VERSION}/site-packages/khard/version.py
+@man man/man1/khard.1
+@man man/man5/khard.conf.5
share/examples/khard/
share/examples/khard/khard.conf.example
share/zsh/
--
Paco Esteban.
5818130B8A6DBC03