Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 30 Mar 2009 05:03:55 -0300
From:      Mario Sergio Fujikawa Ferreira <lioux@FreeBSD.org>
To:        bug-followup@FreeBSD.org
Cc:        gnome@FreeBSD.org, lioux@freebsd.org
Subject:   Re: ports/132231: [PATCH] www/firefox3: Add option to build with Profile-Guided Optimization
Message-ID:  <20090330080355.64208.qmail@exxodus.fedaykin.here>

next in thread | raw e-mail | index | archive | help

--Kj7319i9nmIyA2yE
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

Hi,

	The patch had to be slightly modified after the MAKE_JOBS_SAFE
option was added.

	The updated patch work with Firefox 3.0.8.

	Regards,

-- 
Mario S F Ferreira - DF - Brazil - "I guess this is a signature."
feature, n: a documented bug | bug, n: an undocumented feature

--Kj7319i9nmIyA2yE
Content-Type: text/x-diff; charset=us-ascii
Content-Disposition: attachment; filename=patch

--- Makefile.orig	2009-03-30 03:06:06.000000000 -0300
+++ Makefile	2009-03-30 03:26:55.000000000 -0300
@@ -38,7 +38,6 @@
 HAS_CONFIGURE=	yes
 USE_BZIP2=	yes
 USE_GMAKE=	yes
-MAKE_JOBS_SAFE=	yes
 NO_MOZPKGINSTALL=yes
 
 FIREFOX_ICON=		${MOZILLA}.png
@@ -54,6 +53,7 @@
 
 OPTIONS=	DBUS "Enable D-BUS support" on \
 		NEWTAB "Open external links in a new tab" on \
+		PGO "Enable Profile-Guided Optimization" off \
 		SMB "Enable smb:// URI support using gnomevfs" off
 
 .include <bsd.port.pre.mk>
@@ -73,6 +73,18 @@
 LIB_DEPENDS+=	dbus-glib-1.2:${PORTSDIR}/devel/dbus-glib
 .endif
 
+.if defined(WITH_PGO)
+USE_PYTHON_BUILD=	yes
+.include "${PORTSDIR}/Mk/bsd.python.mk"
+
+MAKEFILE=	client.mk
+ALL_TARGET=	profiledbuild
+
+MAKE_JOBS_UNSAFE=	yes
+.else
+MAKE_JOBS_SAFE=	yes
+.endif
+
 .if ${ARCH} == "sparc64"
 BROKEN=		Does not compile on sparc64
 .endif
@@ -101,6 +113,13 @@
 	    ${LN} -s xptcinvoke_asm_sparc64_openbsd.s xptcinvoke_asm_sparc64_freebsd.s)
 .endif
 
+pre-build:
+.if defined(WITH_PGO)
+	@${SED} -e 's|@PYTHON@|${PYTHON_CMD}|' \
+		< ${FILESDIR}/mozconfig-profile_guided_optimization.in \
+			>> ${BUILD_WRKSRC}/.mozconfig
+.endif
+
 port-pre-install:
 #	${SED} -e 's|1.9a7|0|' ${WRKSRC}/dist/bin/application.ini ${FAKEDIR}/lib
 	${ECHO_CMD} 'share/applications/${MOZILLA}.desktop' >> ${PLISTF}

--Kj7319i9nmIyA2yE
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment;
	filename="mozconfig-profile_guided_optimization.in"

mk_add_options PROFILE_GEN_SCRIPT='@PYTHON@ $(OBJDIR)/_profile/pgo/profileserver.py'

--Kj7319i9nmIyA2yE--



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