diff options
author | Danilo Egea Gondolfo <danilo@FreeBSD.org> | 2013-11-16 23:30:29 +0800 |
---|---|---|
committer | Danilo Egea Gondolfo <danilo@FreeBSD.org> | 2013-11-16 23:30:29 +0800 |
commit | ffcc3f5ecf07623f05acad4c7e23d277ffde4a97 (patch) | |
tree | 70ee415580484b2ee66ab94cde54fc283afdbc58 /games/exmars | |
parent | 95e58be89cb7b0807530c11f0c2c4e6ee0b929d9 (diff) | |
download | freebsd-ports-gnome-ffcc3f5ecf07623f05acad4c7e23d277ffde4a97.tar.gz freebsd-ports-gnome-ffcc3f5ecf07623f05acad4c7e23d277ffde4a97.tar.zst freebsd-ports-gnome-ffcc3f5ecf07623f05acad4c7e23d277ffde4a97.zip |
- Add stage support
- Simplify Makefile
Diffstat (limited to 'games/exmars')
-rw-r--r-- | games/exmars/Makefile | 44 | ||||
-rw-r--r-- | games/exmars/files/patch-Makefile | 6 |
2 files changed, 12 insertions, 38 deletions
diff --git a/games/exmars/Makefile b/games/exmars/Makefile index 2926c181933a..926eec32bf61 100644 --- a/games/exmars/Makefile +++ b/games/exmars/Makefile @@ -16,31 +16,7 @@ ALL_TARGET= ${PORTNAME} OPTIONS_DEFINE= OPTIMIZED_CFLAGS OPTIONS_DEFAULT= OPTIMIZED_CFLAGS -NO_STAGE= yes -do-install: -# Program. - ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin - -# Data. - ${MKDIR} ${DATADIR} - ${CP} -R ${WRKSRC}/warriors ${DATADIR} - ${INSTALL_SCRIPT} ${WRKSRC}/bench.sh ${DATADIR} - -.include <bsd.port.pre.mk> - -# Adjust optimization flags for all architectures. -.if ${ARCH} != "i386" -BADCFLAGS+= -malign-double -.endif -.if ${ARCH} != "amd64" && ${ARCH} != "i386" -BADCFLAGS+= -maccumulate-outgoing-args \ - -minline-all-stringops \ - -mno-align-stringops -.endif -.if ${ARCH} == "alpha" -BADCFLAGS+= -ffast-math \ - -fprefetch-loop-arrays -.endif +.include <bsd.port.options.mk> post-patch: # Fix bench.sh. @@ -48,17 +24,15 @@ post-patch: s|\./exmars|exmars|' \ ${WRKSRC}/bench.sh -# Fix Makefile. - @${REINPLACE_CMD} -e 's|\($${OPT}\)|${CFLAGS} \1|' ${WRKSRC}/${MAKEFILE} - # Enable/disable compilation optimizations. -.if empty(PORT_OPTIONS:MOPTIMIZED_CFLAGS) - @${REINPLACE_CMD} -e 's|$${OPT}||' ${WRKSRC}/${MAKEFILE} +.if ! ${PORT_OPTIONS:MOPTIMIZED_CFLAGS} + @${REINPLACE_CMD} -e 's|$${OPT}|${CFLAGS}|' ${WRKSRC}/${MAKEFILE} .endif -# Adjust optimization flags for all architectures. -.for f in ${BADCFLAGS} - @${REINPLACE_CMD} -e 's|${f}||g' ${WRKSRC}/${MAKEFILE} -.endfor +do-install: + ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin + @${MKDIR} ${STAGEDIR}${DATADIR} + ${CP} -R ${WRKSRC}/warriors ${STAGEDIR}${DATADIR} + ${INSTALL_SCRIPT} ${WRKSRC}/bench.sh ${STAGEDIR}${DATADIR} -.include <bsd.port.post.mk> +.include <bsd.port.mk> diff --git a/games/exmars/files/patch-Makefile b/games/exmars/files/patch-Makefile index daabd0736a77..cc0cb200f6d2 100644 --- a/games/exmars/files/patch-Makefile +++ b/games/exmars/files/patch-Makefile @@ -1,5 +1,5 @@ ---- Makefile.orig Thu Oct 16 04:59:17 2003 -+++ Makefile Thu Jul 7 15:32:24 2005 +--- ./Makefile.orig 2003-10-16 04:59:17.000000000 -0300 ++++ ./Makefile 2013-11-16 13:19:29.000000000 -0200 @@ -1,9 +1,9 @@ # default flags -CCFLAGS = -O3 -fomit-frame-pointer @@ -8,7 +8,7 @@ # my own highly tuned settings #CC = gcc-3.3.1 -#CCFLAGS = -O3 -fomit-frame-pointer -fforce-addr -funroll-all-loops -fstrict-aliasing -malign-double -fprefetch-loop-arrays -maccumulate-outgoing-args -minline-all-stringops -finline-functions -finline-limit=800 -ffast-math -mno-align-stringops -+OPT = -O3 -fomit-frame-pointer -fforce-addr -funroll-all-loops -fstrict-aliasing -malign-double -fprefetch-loop-arrays -maccumulate-outgoing-args -minline-all-stringops -finline-functions -finline-limit=800 -ffast-math -mno-align-stringops ++OPT = -O3 -fomit-frame-pointer -funroll-all-loops -fstrict-aliasing -fprefetch-loop-arrays -minline-all-stringops -finline-functions -ffast-math #CCFLAGS += -mfpmath=sse,387 -mmmx -msse -march=pentium3 # develomental flags |