Mercurial > hgrepos > FreeBSD > ports > PyPy
changeset 34:0ba8512ad4c5
Introduce the PYPY_LDLIBRARY make variable to name the generated PyPy shared library.
This is needed because PyPy3.9 will have names with the minor version in it
(e.g. libpypy3.9-c.so instead of libpypy3-c.so). This is a precondition for
side-by-side installations of PyPy3 implementing different Python versions
(currently 3.7, 3.8 or 3.9).
| author | Franz Glasner <f.glasner@feldmann-mg.com> |
|---|---|
| date | Thu, 06 Oct 2022 12:35:52 +0200 |
| parents | 3fcb2f73b3e2 |
| children | 831b7b2d3e1b |
| files | Makefile bsd.pypy.mk pkg-plist |
| diffstat | 3 files changed, 11 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/Makefile Thu Oct 06 11:38:05 2022 +0200 +++ b/Makefile Thu Oct 06 12:35:52 2022 +0200 @@ -125,7 +125,7 @@ fi post-build: - ${CP} ${BUILD_WRKSRC}/${PORTNAME}-c ${BUILD_WRKSRC}/lib${PORTNAME}-c.so ${WRKSRC}/pypy/goal/ + ${CP} ${BUILD_WRKSRC}/${PORTNAME}-c ${BUILD_WRKSRC}/${PYPY_LDLIBRARY} ${WRKSRC}/pypy/goal/ do-install: ${SETENV} ${MAKE_ENV} TMPDIR=${WRKDIR}/build \
--- a/bsd.pypy.mk Thu Oct 06 11:38:05 2022 +0200 +++ b/bsd.pypy.mk Thu Oct 06 12:35:52 2022 +0200 @@ -10,19 +10,23 @@ PYTHON_IMPL?= ${PORTNAME} PYPY_DIR= ${PYTHON_IMPL}-${DISTVERSION:C|([0-9])\.([0-9]+).*|\1.\2|} -PLIST_SUB+= PYPY_DIR=${PYPY_DIR} PYPY_CFFI_VER=${PYPY_CFFI_VER} +PLIST_SUB+= PYPY_DIR=${PYPY_DIR} \ + PYPY_CFFI_VER=${PYPY_CFFI_VER} \ + PYPY_LDLIBRARY=${PYPY_LDLIBRARY} .if ${PYTHON_IMPL} == pypy DISTVERSION= 7.3.9 PY_VERSION_SHORT= 2.7 PYPY_CFFI_VER= ${PYTHON_IMPL}-73 +PYPY_LDLIBRARY= libpypy-c.so .else # ${PYTHON_IMPL} == pypy3 DISTVERSION= 7.3.9 PYPY_CFFI_VER= ${PYTHON_IMPL_NODOT}-pp${DISTVERSION:S|.||:C|\..*||}-${OPSYS:tl}${OSREL:C|\..*||} -PLIST_SUB+= PYTHON_IMPL_MINOR=${PYTHON_IMPL_MINOR} PY_VERSION_SHORT=${PY_VERSION_SHORT} +PLIST_SUB+= PYTHON_IMPL_MINOR=${PYTHON_IMPL_MINOR} \ + PY_VERSION_SHORT=${PY_VERSION_SHORT} OPTIONS_SINGLE+= FORPYIMPL @@ -48,10 +52,13 @@ .if ${PORT_OPTIONS:MFORPYIMPL37} PY_VERSION_SHORT= 3.7 +PYPY_LDLIBRARY= libpypy3-c.so .endif .if ${PORT_OPTIONS:MFORPYIMPL38} PY_VERSION_SHORT= 3.8 +PYPY_LDLIBRARY= libpypy3-c.so .endif .if ${PORT_OPTIONS:MFORPYIMPL39} PY_VERSION_SHORT= 3.9 +PYPY_LDLIBRARY= libpypy3.9-c.so .endif
--- a/pkg-plist Thu Oct 06 11:38:05 2022 +0200 +++ b/pkg-plist Thu Oct 06 12:35:52 2022 +0200 @@ -1,7 +1,7 @@ bin/pypy %%PYPY_DIR%%/LICENSE %%PYPY_DIR%%/README.rst -%%PYPY_DIR%%/bin/libpypy-c.so +%%PYPY_DIR%%/bin/%%PYPY_LDLIBRARY%% %%PYPY_DIR%%/bin/pypy %%PYPY_DIR%%/bin/pypy2 %%PYPY_DIR%%/bin/pypy2.7
