Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 11 Mar 2023 16:36:57 GMT
From:      Charlie Li <vishwin@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: b883eac8e32d - main - devel/meson: enable FLAVORs
Message-ID:  <202303111636.32BGavvS071833@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by vishwin:

URL: https://cgit.FreeBSD.org/ports/commit/?id=b883eac8e32d2187ad18a7247699f77084cf0f06

commit b883eac8e32d2187ad18a7247699f77084cf0f06
Author:     Charlie Li <vishwin@FreeBSD.org>
AuthorDate: 2023-03-09 19:45:19 +0000
Commit:     Charlie Li <vishwin@FreeBSD.org>
CommitDate: 2023-03-11 16:35:57 +0000

    devel/meson: enable FLAVORs
    
    Needed for devel/meson-python to function on non-default Python
    flavours/distributions, as meson is imported as a module. Existing
    USES=meson consumers not affected.
    
    Reported by: fluffy
    Differential Revision: https://reviews.freebsd.org/D39004
---
 Mk/Uses/meson.mk            |  2 +-
 devel/meson-python/Makefile |  4 ++--
 devel/meson/Makefile        | 10 ++++++++--
 3 files changed, 11 insertions(+), 5 deletions(-)

diff --git a/Mk/Uses/meson.mk b/Mk/Uses/meson.mk
index 4411bb5b9f7b..9affd4b9ed4e 100644
--- a/Mk/Uses/meson.mk
+++ b/Mk/Uses/meson.mk
@@ -24,7 +24,7 @@ _INCLUDE_USES_MESON_MK=	yes
 IGNORE=	Incorrect 'USES+= meson:${meson_ARGS}'. meson takes no arguments
 .  endif
 
-BUILD_DEPENDS+=		meson>=0.57.1_1:devel/meson
+BUILD_DEPENDS+=		meson:devel/meson
 
 # meson uses ninja
 .include "${USESDIR}/ninja.mk"
diff --git a/devel/meson-python/Makefile b/devel/meson-python/Makefile
index 283d6ce78041..144ee459712a 100644
--- a/devel/meson-python/Makefile
+++ b/devel/meson-python/Makefile
@@ -12,9 +12,9 @@ WWW=		https://github.com/mesonbuild/meson-python
 LICENSE=	MIT
 LICENSE_FILE=	${WRKSRC}/LICENSE
 
-BUILD_DEPENDS=	meson>=0.63.3:devel/meson \
+BUILD_DEPENDS=	meson:devel/meson@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}pyproject-metadata>=0.6.1:devel/py-pyproject-metadata@${PY_FLAVOR}
-RUN_DEPENDS=	meson>=0.63.3:devel/meson \
+RUN_DEPENDS=	meson:devel/meson@${PY_FLAVOR} \
 		${PYTHON_PKGNAMEPREFIX}pyproject-metadata>=0.6.1:devel/py-pyproject-metadata@${PY_FLAVOR}
 
 USES=		python
diff --git a/devel/meson/Makefile b/devel/meson/Makefile
index 00d2889f4baf..83793c5990b8 100644
--- a/devel/meson/Makefile
+++ b/devel/meson/Makefile
@@ -13,7 +13,7 @@ LICENSE_FILE=	${WRKSRC}/COPYING
 TEST_DEPENDS=	${PYTHON_PKGNAMEPREFIX}pytest-xdist>0:devel/py-pytest-xdist@${PY_FLAVOR}
 
 USES=		ninja:run python:3.6+ shebangfix
-USE_PYTHON=	autoplist distutils noflavors
+USE_PYTHON=	autoplist distutils
 SHEBANG_FILES=	mesonbuild/rewriter.py \
 		mesonbuild/scripts/cmake_run_ctgt.py
 NO_ARCH=	yes
@@ -28,7 +28,13 @@ BINARY_ALIAS+=	python3=${PYTHON_CMD:T} python=${PYTHON_CMD:T}
 do-test: create-binary-alias # force if run late
 .endif
 
+.include <bsd.port.pre.mk>
+
+.if ${PYTHON_VER} != ${PYTHON_DEFAULT}
+PKGNAMESUFFIX=	${PYTHON_PKGNAMESUFFIX}
+.endif
+
 do-test:
 	@(cd ${TEST_WRKSRC} && ${SETENV} ${TEST_ENV} ${PYTHON_CMD} ${WRKSRC}/run_unittests.py)
 
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202303111636.32BGavvS071833>