pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/devel/scons4



Module Name:    pkgsrc
Committed By:   wiz
Date:           Thu Jun  8 05:28:43 UTC 2023

Modified Files:
        pkgsrc/devel/scons4: Makefile build.mk

Log Message:
scons4: carry over rpath hack from devel/scons

Improve build.mk, add test target.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 pkgsrc/devel/scons4/Makefile \
    pkgsrc/devel/scons4/build.mk

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/devel/scons4/Makefile
diff -u pkgsrc/devel/scons4/Makefile:1.1 pkgsrc/devel/scons4/Makefile:1.2
--- pkgsrc/devel/scons4/Makefile:1.1    Wed Jun  7 18:25:03 2023
+++ pkgsrc/devel/scons4/Makefile        Thu Jun  8 05:28:43 2023
@@ -1,7 +1,8 @@
-# $NetBSD: Makefile,v 1.1 2023/06/07 18:25:03 wiz Exp $
+# $NetBSD: Makefile,v 1.2 2023/06/08 05:28:43 wiz Exp $
 
 DISTNAME=      SCons-4.5.2
 PKGNAME=       ${PYPKGPREFIX}-${DISTNAME:tl}
+PKGREVISION=   1
 CATEGORIES=    devel python
 MASTER_SITES=  ${MASTER_SITE_PYPI:=S/SCons/}
 
@@ -20,6 +21,13 @@ REPLACE_PYTHON+=     script/sconsign
 
 PYTHON_VERSIONS_INCOMPATIBLE=  27
 
+# XXX: not sure why this is needed exactly
+# but -Wl,-rpath is filtered out by buildlink from the c++ command line
+SUBST_CLASSES+=                rflag
+SUBST_STAGE.rflag=     pre-configure
+SUBST_FILES.rflag=     SCons/Tool/gnulink.py
+SUBST_SED.rflag=       -e 's|-Wl,-rpath=|${COMPILER_RPATH_FLAG}|g'
+
 INSTALLATION_DIRS=     ${PKGMANDIR}/man1
 
 post-install:
Index: pkgsrc/devel/scons4/build.mk
diff -u pkgsrc/devel/scons4/build.mk:1.1 pkgsrc/devel/scons4/build.mk:1.2
--- pkgsrc/devel/scons4/build.mk:1.1    Wed Jun  7 18:25:03 2023
+++ pkgsrc/devel/scons4/build.mk        Thu Jun  8 05:28:43 2023
@@ -1,4 +1,4 @@
-# $NetBSD: build.mk,v 1.1 2023/06/07 18:25:03 wiz Exp $
+# $NetBSD: build.mk,v 1.2 2023/06/08 05:28:43 wiz Exp $
 #
 # This Makefile fragment supports building using the SCons build tool.
 #
@@ -7,6 +7,9 @@
 # SCONS_BUILD_ARGS
 #      Arguments to pass to SCons during build. Default: empty
 #
+# SCONS_TEST_ARGS
+#      Arguments to pass to SCons during testing. Default: empty
+#
 # SCONS_INSTALL_ARGS
 #      Arguments to pass to SCons during installation: Default: empty
 #
@@ -20,28 +23,37 @@ TOOL_DEPENDS+=      ${PYPKGPREFIX}-scons>=4:.
 SCONSBIN=      scons-${PYVERSSUFFIX}
 
 _SCONS_BUILD_ARGS+=    PREFIX=${PREFIX}
+_SCONS_BUILD_ARGS+=    -j${MAKE_JOBS:U1}
 _SCONS_BUILD_ARGS+=    ${SCONS_BUILD_ARGS}
 _SCONS_INSTALL_ARGS+=  ${_SCONS_BUILD_ARGS}
 _SCONS_INSTALL_ARGS+=  ${SCONS_INSTALL_ARGS}
+_SCONS_TEST_ARGS+=     ${_SCONS_BUILD_ARGS}
+_SCONS_TEST_ARGS+=     ${SCONS_TEST_ARGS}
 
-.PHONY: scons-build scons-install
+.PHONY: scons-build scons-test scons-install
 
 do-build: scons-build
 scons-build:
        cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${SCONSBIN} ${_SCONS_BUILD_ARGS}
 
+do-test: scons-test
+scons-test:
+       cd ${WRKSRC} && ${SETENV} ${TEST_ENV} ${SCONSBIN} ${_SCONS_TEST_ARGS} check
+
 do-install: scons-install
 scons-install:
-       cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${SCONSBIN} ${_SCONS_INSTALL_ARGS} install
+       cd ${WRKSRC} && ${SETENV} ${INSTALL_ENV} ${SCONSBIN} ${_SCONS_INSTALL_ARGS} install
 
 _VARGROUPS+=           scons
 _PKG_VARS.scons+=      PYPKGPREFIX
 _PKG_VARS.scons+=      SCONS_BUILD_ARGS
+_PKG_VARS.scons+=      SCONS_TEST_ARGS
 _PKG_VARS.scons+=      SCONS_INSTALL_ARGS
 _PKG_VARS.scons+=      SCONSBIN
 _PKG_VARS.scons+=      _SCONS_BUILD_ARGS
+_PKG_VARS.scons+=      _SCONS_TEST_ARGS
 _PKG_VARS.scons+=      _SCONS_INSTALL_ARGS
-_IGN_VARS.scons+=      MAKE_ENV PREFIX WRKSRC PYVERSSUFFIX PYTHON_FOR_BUILD_ONLY
+_IGN_VARS.scons+=      MAKE_ENV MAKE_JOBS PREFIX WRKSRC PYVERSSUFFIX PYTHON_FOR_BUILD_ONLY
 _IGN_VARS.scons+=      SETENV TOOL_DEPENDS
 #_LISTED_VARS.scons+=  *_ARGS
 #_SORTED_VARS.scons+=  *_ENV



Home | Main Index | Thread Index | Old Index