svn commit: r568854 - head/games/anki
Kai Knoblich
kai at FreeBSD.org
Sat Mar 20 08:39:28 UTC 2021
Author: kai
Date: Sat Mar 20 08:39:27 2021
New Revision: 568854
URL: https://svnweb.freebsd.org/changeset/ports/568854
Log:
games/anki: Fix packaging with Python 3.8
* Add a workaround to make the transition from Python 3.7 to Python 3.8
possible because the name of the .so file is slightly different between
the two releases.
* Also add CARGO_INSTALL to avoid warnings about ignored duplicate scripts
for the target "do-install".
PR: 253815
Modified:
head/games/anki/Makefile
head/games/anki/pkg-plist
Modified: head/games/anki/Makefile
==============================================================================
--- head/games/anki/Makefile Sat Mar 20 08:33:25 2021 (r568853)
+++ head/games/anki/Makefile Sat Mar 20 08:39:27 2021 (r568854)
@@ -325,6 +325,7 @@ CARGO_CARGOLOCK= ${WRKSRC}/rspy/Cargo.lock
CARGO_CARGOTOML= ${WRKSRC}/rspy/Cargo.toml
CARGO_BUILD= no
+CARGO_INSTALL= no
MAKE_ARGS= DEVEL="rspy pylib ts qt" PYTHON_FILE="${PYTHON_CMD}" SHELL="${LOCALBASE}/bin/bash"
# devel/py-maturin acts as a wrapper for "cargo" and "rustc". Ensure that it
@@ -334,6 +335,8 @@ MAKE_ENV= ${CARGO_ENV} npm_config_offline=true
ALL_TARGET= build
+PLIST_SUB= _PY_SONAME=${_PY_SONAME}
+
OPTIONS_DEFINE= NLS
OPTIONS_DEFAULT= MPV
OPTIONS_GROUP= PLAYER
@@ -352,6 +355,14 @@ NLS_USES= gettext
# expected.
_MY_BUILDHASH= 84dcaa86
+.include <bsd.port.pre.mk>
+
+.if ${PYTHON_REL} < 3800
+_PY_SONAME= .cpython-${PYTHON_SUFFIX}m
+.else
+_PY_SONAME= ${PYTHON_EXT_SUFFIX}
+.endif
+
# Place the translation files to the appropriate directories
post-extract:
@${RLN} ${WRKSRC_i18ncore} ${WRKSRC}/rslib/ftl/repo
@@ -434,4 +445,4 @@ make-npm-cache:
&& ${TAR} -czf ${PORTNAME}-npm-cache-${DISTVERSION}${EXTRACT_SUFX} .npm \
&& ${ECHO} "Please upload the file ${WRKDIR}/${PORTNAME}-npm-cache-${DISTVERSION}${EXTRACT_SUFX}"
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
Modified: head/games/anki/pkg-plist
==============================================================================
--- head/games/anki/pkg-plist Sat Mar 20 08:33:25 2021 (r568853)
+++ head/games/anki/pkg-plist Sat Mar 20 08:39:27 2021 (r568854)
@@ -138,7 +138,7 @@ man/man1/anki.1.gz
%%DATADIR%%/anki/template_legacy.py
%%DATADIR%%/anki/types.py
%%DATADIR%%/anki/utils.py
-%%DATADIR%%/ankirspy.cpython-%%PYTHON_SUFFIX%%m.so
+%%DATADIR%%/ankirspy%%_PY_SONAME%%.so
%%DATADIR%%/aqt/__init__.py
%%DATADIR%%/aqt/__pycache__/__init__.cpython-%%PYTHON_SUFFIX%%.opt-1.pyc
%%DATADIR%%/aqt/__pycache__/__init__.cpython-%%PYTHON_SUFFIX%%.pyc
More information about the svn-ports-head
mailing list