From 7427df0fcf43c8c5c6fabc9c934708256293cbb6 Mon Sep 17 00:00:00 2001 From: Alex Kozlov Date: Mon, 9 Jul 2012 12:37:07 +0000 Subject: [PATCH] - Remove wrapper script - Use REINPLACE_CMD instead of patch file Approved by: maintainer timeout (2 weeks) --- games/sdl_jewels/Makefile | 20 +++++++++++++------- games/sdl_jewels/files/patch-Makefile | 11 ----------- 2 files changed, 13 insertions(+), 18 deletions(-) delete mode 100644 games/sdl_jewels/files/patch-Makefile diff --git a/games/sdl_jewels/Makefile b/games/sdl_jewels/Makefile index 1dc77f34b655..b72429ab6d16 100644 --- a/games/sdl_jewels/Makefile +++ b/games/sdl_jewels/Makefile @@ -28,16 +28,22 @@ PORTDOCS= ChangeLog README ALL_TARGET= +post-patch: + @${RM} -rf ${WRKSRC}/data/CVS +# Fix data location + @${REINPLACE_CMD} -e 's!data/bigfont.ppm!${DATADIR}/data/bigfont.ppm!' \ + -e 's!dirlist\[\]="data";!dirlist[]="${DATADIR}/data";'! \ + -e 's!char name[256],!char name[512],!' \ + ${WRKSRC}/gljewel.c ${WRKSRC}/sound.c +# Fix CFLAGS/LDFLAGS + @${REINPLACE_CMD} -e 's!CFLAGS = -O2 -Wall!CFLAGS+=!' \ + -e 's!LDFLAGS =!LDFLAGS+=!' ${WRKSRC}/Makefile + do-install: -# Scripts - @${PRINTF} "#!/bin/sh\n\ncd ${DATADIR} &&\ - ./gljewel\n" > ${WRKDIR}/sdljewels.sh - @${INSTALL_SCRIPT} ${WRKDIR}/sdljewels.sh ${PREFIX}/bin/sdljewels # Executable - ${MKDIR} ${DATADIR} - ${INSTALL_PROGRAM} ${WRKSRC}/gljewel ${DATADIR} + ${INSTALL_PROGRAM} ${WRKSRC}/gljewel ${PREFIX}/bin/sdljewels # Data - @(cd ${WRKSRC} && ${COPYTREE_SHARE} data ${DATADIR}) + (cd ${WRKSRC} && ${COPYTREE_SHARE} data ${DATADIR}) # Documentation .if !defined(NOPORTDOCS) diff --git a/games/sdl_jewels/files/patch-Makefile b/games/sdl_jewels/files/patch-Makefile deleted file mode 100644 index a696152b674b..000000000000 --- a/games/sdl_jewels/files/patch-Makefile +++ /dev/null @@ -1,11 +0,0 @@ -Index: Makefile -@@ -1,7 +1,7 @@ - EXE = gljewel - --CFLAGS = -O2 -Wall $(shell sdl-config --cflags) --LDFLAGS = $(shell sdl-config --libs) -lGL -lm -+CFLAGS += $(shell sdl-config --cflags) -+LDFLAGS += $(shell sdl-config --libs) -lGL -lm - - OBJS = $(EXE).o matrix.o sound.o -