Annotation of pkgsrc/lang/python/bootstrap.mk, revision 1.4
1.4 ! wiz 1: # $NetBSD: bootstrap.mk,v 1.3 2023/10/25 22:49:02 wiz Exp $
1.1 wiz 2: #
3: # Initial mk for building and installing Python packages that
4: # are on the module install bootstrap path.
5: #
6: # As of October 2023, this consists of
7: # - devel/py-flit_core (has own build rules)
8: # - misc/py-installer (has own build rules)
9: # - devel/py-build and its dependencies:
10: # - devel/py-packaging
11: # - devel/py-pyparsing
12: # - devel/py-pyproject_hooks
13:
1.3 wiz 14: PY_PATCHPLIST?= yes
1.1 wiz 15:
16: WHEELFILE?= ${WRKSRC}/dist/*.whl
17: WHEEL_NAME?= ${DISTNAME:C/-([^0-9])/_\1/g}
18: _WHEEL_INFODIR= ${WHEEL_NAME}.dist-info
19: PLIST_SUBST+= WHEEL_INFODIR=${_WHEEL_INFODIR}
20:
21: PRINT_PLIST_AWK+= { gsub(/${_WHEEL_INFODIR:S,.,\.,g}/, "$${WHEEL_INFODIR}") }
22:
23: .if !target(do-build)
1.4 ! wiz 24: TOOL_DEPENDS+= ${PYPKGPREFIX}-flit_core>=3.11.0:../../devel/py-flit_core
1.1 wiz 25: do-build:
26: ${RUN} cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${TOOL_PYTHONBIN} -m flit_core.wheel
27: .endif
28:
29: .if !target(do-install)
1.2 wiz 30: TOOL_DEPENDS+= ${PYPKGPREFIX}-installer>=0.7.0nb1:../../misc/py-installer
1.1 wiz 31: do-install:
32: ${RUN} cd ${WRKSRC} && \
33: ${SETENV} ${INSTALL_ENV} \
34: ${TOOL_PYTHONBIN} -m installer --destdir ${DESTDIR:Q} \
35: --prefix ${PREFIX:Q} ${WHEELFILE}
36: .endif
37:
38: .include "../../lang/python/extension.mk"
CVSweb <webmaster@jp.NetBSD.org>