Files
ports/dns/py-pycares/Makefile
T
Kai Knoblich 9cb5898561 Relax hardcoded paths to fix build with Python 3.8.7
Since r558913 Python 3.8 incorporates BPO-42604 [1] which changed the
shared libs naming scheme.  This means "EXT_SUFFIX" is now derived from
SOABI and yields with Python 3.8 to ".cpython-38.so" instead of ".so".

The affected ports strip the libaries in the "post-install" target via
hardcoded path(s) and the build fails at the end because the new extension
is not expected at this place.

Remedy the issue by adding wildcards to these paths.  This should also
prepare the ports for future Python releases, which will use the new shared
libs naming scheme.

[1] https://bugs.python.org/issue42604

PR:		252057
Reported by:	John Kennedy
Reviewed by:	fluffy, koobs
Approved by:	koobs (python)
2020-12-24 13:46:01 +00:00

34 lines
933 B
Makefile

# Created by: Dmitry Sivachenko <mitya@yandex-team.ru>
# $FreeBSD$
PORTNAME= pycares
PORTVERSION= 3.1.1
CATEGORIES= dns python
MASTER_SITES= CHEESESHOP
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
MAINTAINER= demon@FreeBSD.org
COMMENT= Python interface to c-ares
LICENSE= MIT
LICENSE_FILE= ${WRKSRC}/LICENSE
BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}cffi>=1.5.0:devel/py-cffi@${PY_FLAVOR}
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}cffi>=1.5.0:devel/py-cffi@${PY_FLAVOR}
USES= python:3.5+
USE_PYTHON= distutils autoplist
OPTIONS_DEFINE= IDNA
IDNA_DESC= IDNA support
IDNA_BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}idna>0:dns/py-idna@${PY_FLAVOR}
IDNA_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}idna>0:dns/py-idna@${PY_FLAVOR}
post-install:
${STRIP_CMD} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/${PORTNAME}/_cares*.so
do-test:
cd ${WRKSRC} && ${SETENV} PYTHONPATH=${STAGEDIR}${PYTHONPREFIX_SITELIBDIR} ${PYTHON_CMD} tests/tests.py
.include <bsd.port.mk>