On Tuesday 26 May 2009 23:23:16 Pav Lucistnik wrote:
> David Naylor píše v út 26. 05. 2009 v 18:17 +0200:
> > What about the change that exposes MAKE_JOBS_NUMBER when MAKE_JOBS_SAFE
> > or FORCE_MAKE_JOBS are defined (to avoid using ${_MAKE_JOBS:C/-j//}, not
> > sure what the policy is of ports using *.mk internals).  I think that is
> > a reasonable change???
>
> I think it's reasonable. It will need to be tested widely. Can you file
> a PR with just that change, to help me track it while in testing?

Done, please see PR ports/134977.  This should not have any functional change 
and the only ports (at this stage) that will use MAKE_JOBS_NUMBER is OOo* 
(although games/teeworld is the next closest candidate).  

I've also made some changes to how OOo2 handles concurrency, as pav@ pointed 
out `make -j1` is different to `make` and OOo2 now differentiates between the 
two, could someone please check if the following work:
(cd /usr/ports/editors/openoffice.org-2; make MAKE_JOBS_NUMBER=1) 

OOo3 should be functionally the same to the previous patch however it does not 
make the distinction between `make -j1` and `make` and I don't know enough 
about the build process to know how to add a normal `make`.  

Thanks for all your patience.  

David

P.S. This should have been sent ~9 hours ago, but internet went down.
P.P.S. This should be the final patch (pending OOo2 verification).
diff -ur /usr/ports/Mk/bsd.port.mk ports/Mk/bsd.port.mk
--- /usr/ports/Mk/bsd.port.mk	2009-05-23 13:20:58.000000000 +0200
+++ ports/Mk/bsd.port.mk	2009-05-27 08:38:44.000000000 +0200
@@ -2185,11 +2185,8 @@
 _MAKE_JOBS=		#
 .else
 .if defined(MAKE_JOBS_SAFE) || defined(FORCE_MAKE_JOBS)
-.if defined(MAKE_JOBS_NUMBER)
+MAKE_JOBS_NUMBER?=	`${SYSCTL} -n kern.smp.cpus`
 _MAKE_JOBS=		-j${MAKE_JOBS_NUMBER}
-.else
-_MAKE_JOBS=		-j`${SYSCTL} -n kern.smp.cpus`
-.endif
 .if defined(FORCE_MAKE_JOBS)
 BUILD_FAIL_MESSAGE+=	"You have chosen to use multiple make jobs (parallelization) for all ports.  This port was not tested for this setting.  Please remove FORCE_MAKE_JOBS and retry the build before reporting the failure to the maintainer."
 .endif
diff -ur /usr/ports/editors/openoffice.org-2/Makefile ports/editors/openoffice.org-2/Makefile
--- /usr/ports/editors/openoffice.org-2/Makefile	2009-01-25 10:45:45.000000000 +0200
+++ ports/editors/openoffice.org-2/Makefile	2009-05-27 08:38:27.000000000 +0200
@@ -51,6 +51,7 @@
 USE_PERL5=	yes
 USE_BZIP2=	yes
 WITHOUT_CPU_CFLAGS=	true
+MAKE_JOBS_SAFE=	yes
 
 .include <bsd.port.pre.mk>
 
@@ -132,7 +133,6 @@
 CONFIGURE_WRKSRC=	${WRKSRC}/config_office
 TCSH?=		/bin/tcsh
 PKGMESSAGE=	${WRKDIR}/pkg-message
-NUMOFPROCESSES?=	1
 
 CONFIGURE_ARGS+=	--with-gnu-cp=${LOCALBASE}/bin/gcp		\
 			--with-gnu-patch=${LOCALBASE}/bin/gpatch	\
@@ -192,8 +192,8 @@
 do-build:
 	@cd ${WRKSRC} ; ./bootstrap
 # PR:84786 #i53289#
-.if (${NUMOFPROCESSES}>1)
-	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; setenv TMP ${WRKSRC} ; cd instsetoo_native ; build.pl -P${NUMOFPROCESSES} --all"
+.if !defined(DISABLE_MAKE_JOBS)
+	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; setenv TMP ${WRKSRC} ; cd instsetoo_native ; build.pl -P${MAKE_JOBS_NUMBER} --all"
 .else
 	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; setenv TMP ${WRKSRC} ; dmake"
 .endif
diff -ur /usr/ports/editors/openoffice.org-2-RC/Makefile ports/editors/openoffice.org-2-RC/Makefile
--- /usr/ports/editors/openoffice.org-2-RC/Makefile	2009-01-25 10:45:45.000000000 +0200
+++ ports/editors/openoffice.org-2-RC/Makefile	2009-05-27 08:41:53.000000000 +0200
@@ -52,6 +52,7 @@
 USE_PERL5=	yes
 USE_BZIP2=	yes
 WITHOUT_CPU_CFLAGS=	true
+MAKE_JOBS_SAFE=	yes
 
 .include <bsd.port.pre.mk>
 
@@ -134,7 +135,6 @@
 CONFIGURE_WRKSRC=	${WRKSRC}/config_office
 TCSH?=		/bin/tcsh
 PKGMESSAGE=	${WRKDIR}/pkg-message
-NUMOFPROCESSES?=	1
 
 CONFIGURE_ARGS+=	--with-gnu-cp=${LOCALBASE}/bin/gcp		\
 			--with-gnu-patch=${LOCALBASE}/bin/gpatch	\
@@ -194,8 +194,8 @@
 do-build:
 	@cd ${WRKSRC} ; ./bootstrap
 # PR:84786 #i53289#
-.if (${NUMOFPROCESSES}>1)
-	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; setenv TMP ${WRKSRC} ; cd instsetoo_native ; build.pl -P${NUMOFPROCESSES} --all"
+.if !defined(DISABLE_MAKE_JOBS)
+	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; setenv TMP ${WRKSRC} ; cd instsetoo_native ; build.pl -P${MAKE_JOBS_NUMBER} --all"
 .else
 	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; setenv TMP ${WRKSRC} ; dmake"
 .endif
diff -ur /usr/ports/editors/openoffice.org-2-devel/Makefile ports/editors/openoffice.org-2-devel/Makefile
--- /usr/ports/editors/openoffice.org-2-devel/Makefile	2009-01-25 10:45:45.000000000 +0200
+++ ports/editors/openoffice.org-2-devel/Makefile	2009-05-27 08:46:03.000000000 +0200
@@ -52,6 +52,7 @@
 USE_PERL5=	yes
 USE_BZIP2=	yes
 WITHOUT_CPU_CFLAGS=	true
+MAKE_JOBS_SAFE=	yes
 
 .include <bsd.port.pre.mk>
 
@@ -137,8 +138,10 @@
 CONFIGURE_WRKSRC=	${WRKSRC}/config_office
 TCSH?=		/bin/tcsh
 PKGMESSAGE=	${WRKDIR}/pkg-message
-MAXPROCESSES?=	1
-MAXMODULES?=	1
+
+.if defined(DISABLE_MAKE_JOBS)
+MAKE_JOBS_NUMBER=	1
+.endif
 
 CONFIGURE_ARGS+=	--with-gnu-cp=${LOCALBASE}/bin/gcp		\
 			--with-gnu-patch=${LOCALBASE}/bin/gpatch	\
@@ -200,7 +203,7 @@
 
 do-build:
 	@cd ${WRKSRC} ; ./bootstrap
-	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; setenv TMP ${WRKSRC} ; cd instsetoo_native ; build.pl --checkmodules ; build.pl -P${MAXMODULES} --all --html --dontgraboutput -- -P${MAXPROCESSES}"
+	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; setenv TMP ${WRKSRC} ; cd instsetoo_native ; build.pl --checkmodules ; build.pl -P${MAKE_JOBS_NUMBER} --all --html --dontgraboutput -- -P${MAKE_JOBS_NUMBER}"
 
 .if ${LOCALIZED_LANG} == "alllangs"
 	@${MAKE} languagepack
diff -ur /usr/ports/editors/openoffice.org-3/Makefile ports/editors/openoffice.org-3/Makefile
--- /usr/ports/editors/openoffice.org-3/Makefile	2009-05-21 20:14:02.000000000 +0200
+++ ports/editors/openoffice.org-3/Makefile	2009-05-27 08:47:30.000000000 +0200
@@ -50,6 +50,7 @@
 USE_PERL5=	yes
 USE_BZIP2=	yes
 WITHOUT_CPU_CFLAGS=	true
+MAKE_JOBS_SAFE=	yes
 
 .include <bsd.port.pre.mk>
 
@@ -134,8 +135,10 @@
 WRKSRC?=		${WRKDIR}/${OOOTAG}
 TCSH?=		/bin/tcsh
 PKGMESSAGE=	${WRKDIR}/pkg-message
-MAXPROCESSES?=	1
-MAXMODULES?=	1
+
+.if defined(DISABLE_MAKE_JOBS)
+MAKE_JOBS_NUMBER=	1
+.endif
 
 CONFIGURE_ARGS+=	--with-gnu-cp=${LOCALBASE}/bin/gcp		\
 			--with-gnu-patch=${LOCALBASE}/bin/gpatch	\
@@ -201,7 +204,7 @@
 
 do-build:
 	@cd ${WRKSRC} ; ./bootstrap
-	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" "TMP=${WRKSRC}" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; cd instsetoo_native ; build.pl --checkmodules ; build.pl -P${MAXMODULES} --all --html --dontgraboutput -- -P${MAXPROCESSES}"
+	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" "TMP=${WRKSRC}" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; cd instsetoo_native ; build.pl --checkmodules ; build.pl -P${MAKE_JOBS_NUMBER} --all --html --dontgraboutput -- -P${MAKE_JOBS_NUMBER}"
 
 .if ${LOCALIZED_LANG} == "alllangs"
 	@${MAKE} languagepack
diff -ur /usr/ports/editors/openoffice.org-3-RC/Makefile ports/editors/openoffice.org-3-RC/Makefile
--- /usr/ports/editors/openoffice.org-3-RC/Makefile	2009-05-21 20:14:06.000000000 +0200
+++ ports/editors/openoffice.org-3-RC/Makefile	2009-05-27 08:49:14.000000000 +0200
@@ -50,6 +50,7 @@
 USE_PERL5=	yes
 USE_BZIP2=	yes
 WITHOUT_CPU_CFLAGS=	true
+MAKE_JOBS_SAFE=	yes
 
 .include <bsd.port.pre.mk>
 
@@ -135,8 +136,10 @@
 WRKSRC?=		${WRKDIR}/${OOOTAG}
 TCSH?=		/bin/tcsh
 PKGMESSAGE=	${WRKDIR}/pkg-message
-MAXPROCESSES?=	1
-MAXMODULES?=	1
+
+.if defined(DISABLE_MAKE_JOBS)
+MAKE_JOBS_NUMBER=	1
+.endif
 
 USE_AUTOTOOLS=		autoconf:262
 CONFIGURE_ARGS+=	--with-gnu-cp=${LOCALBASE}/bin/gcp		\
@@ -203,7 +206,7 @@
 
 do-build:
 	@cd ${WRKSRC} ; ./bootstrap
-	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" "TMP=${WRKSRC}" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; cd instsetoo_native ; build.pl --checkmodules ; build.pl -P${MAXMODULES} --all --html --dontgraboutput -- -P${MAXPROCESSES}"
+	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" "TMP=${WRKSRC}" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; cd instsetoo_native ; build.pl --checkmodules ; build.pl -P${MAKE_JOBS_NUMBER} --all --html --dontgraboutput -- -P${MAKE_JOBS_NUMBER}"
 
 .if ${LOCALIZED_LANG} == "alllangs"
 	@${MAKE} languagepack
diff -ur /usr/ports/editors/openoffice.org-3-devel/Makefile ports/editors/openoffice.org-3-devel/Makefile
--- /usr/ports/editors/openoffice.org-3-devel/Makefile	2009-05-27 03:05:47.000000000 +0200
+++ ports/editors/openoffice.org-3-devel/Makefile	2009-05-27 08:50:58.000000000 +0200
@@ -48,6 +48,7 @@
 USE_PERL5=	yes
 USE_BZIP2=	yes
 WITHOUT_CPU_CFLAGS=	true
+MAKE_JOBS_SAFE=	yes
 
 .include <bsd.port.pre.mk>
 
@@ -134,8 +135,10 @@
 WRKSRC?=		${WRKDIR}/${OOOTAG}
 TCSH?=		/bin/tcsh
 PKGMESSAGE=	${WRKDIR}/pkg-message
-MAXPROCESSES?=	1
-MAXMODULES?=	1
+
+.if defined(DISABLE_MAKE_JOBS)
+MAKE_JOBS_NUMBER=	1
+.endif
 
 CONFIGURE_ARGS+=	--with-gnu-cp=${LOCALBASE}/bin/gcp		\
 			--with-gnu-patch=${LOCALBASE}/bin/gpatch	\
@@ -201,7 +204,7 @@
 
 do-build:
 	@cd ${WRKSRC} ; ./bootstrap
-	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" "TMP=${WRKSRC}" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; cd instsetoo_native ; build.pl --checkmodules ; build.pl -P${MAXMODULES} --all --html --dontgraboutput -- -P${MAXPROCESSES}"
+	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" "TMP=${WRKSRC}" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; cd instsetoo_native ; build.pl --checkmodules ; build.pl -P${MAKE_JOBS_NUMBER} --all --html --dontgraboutput -- -P${MAKE_JOBS_NUMBER}"
 
 .if ${LOCALIZED_LANG} == "alllangs"
 	@${MAKE} languagepack

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply via email to