ports/67132: [ maintainer ] emulators/pearpc: some tweaks
Roman Bogorodskiy
bogorodskiy at inbox.ru
Mon May 24 18:00:58 UTC 2004
>Number: 67132
>Category: ports
>Synopsis: [ maintainer ] emulators/pearpc: some tweaks
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: maintainer-update
>Submitter-Id: current-users
>Arrival-Date: Mon May 24 11:00:42 PDT 2004
>Closed-Date:
>Last-Modified:
>Originator: Roman Bogorodskiy
>Release: FreeBSD 5.2.1-RELEASE-p6 i386
>Organization:
>Environment:
System: FreeBSD lame.novel.ru 5.2.1-RELEASE-p6 FreeBSD 5.2.1-RELEASE-p6 #0: Tue May 18 12:31:41 MSD 2004 root at lame.novel.ru:/usr/obj/usr/src/sys/NOV i386
>Description:
User now can choose CPU type: generic or jitc_x86 (the last one
is for x86 only thougth). Added OPTIMIZED_BUILD option, since
PearPC is rather slow and it would be nice to use optimized
CPPFLAGS to make it a little bit faster.
>How-To-Repeat:
>Fix:
diff -ruN pearpc.bak/Makefile pearpc/Makefile
--- pearpc.bak/Makefile Mon May 24 20:14:40 2004
+++ pearpc/Makefile Mon May 24 21:41:38 2004
@@ -19,9 +19,34 @@
GNU_CONFIGURE= yes
CONFIGURE_ENV= CPPFLAGS="-I${X11BASE}/include" \
LDFLAGS="-L${X11BASE}/lib"
-CONFIGURE_ARGS= --disable-fpo
PKGMESSAGE= ${WRKDIR}/pkg-message
+.include <bsd.port.pre.mk>
+
+.if defined(OPTIMIZED_BUILD)
+CFLAGS+= -O3 -ffast-math
+.else
+CONFIGURE_ARGS+= --disable-fpo
+.endif
+
+# jitc_x86 is avaible only on x86
+.if ${ARCH} == "i386"
+.if !defined(WITH_JITC)
+CONFIGURE_ARGS+= --enable-cpu=generic
+.else
+CONFIGURE_ARGS+= --enable-cpu=jitc_x86
+.endif # WITH_JITC
+.else
+CONFIGURE_ARGS+= --enable-cpu=generic
+.endif
+
+pre-everything::
+.if !defined(OPTIMIZED_BUILD)
+ @${ECHO_MSG} ""
+ @${ECHO_MSG} "You can do optimized build defining OPTIMIZED_BUILD=yes."
+ @${ECHO_MSG} ""
+.endif
+
post-configure:
@${REINPLACE_CMD} -e 's|-lpthread|${PTHREAD_LIBS}|g' ${WRKSRC}/Makefile
@${REINPLACE_CMD} -e 's|-lpthread|${PTHREAD_LIBS}|g' ${WRKSRC}/src/Makefile
@@ -33,4 +58,4 @@
@${CAT} ${PKGMESSAGE}
@${INSTALL_DATA} ${WRKSRC}/ppccfg.example ${PREFIX}/etc/ppccfg.example
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list