View | Details | Raw Unified | Return to bug 53859
Collapse All | Expand All

(-)toppler/Makefile (-15 / +3 lines)
Lines 6-12 Link Here
6
#
6
#
7
7
8
PORTNAME=	toppler
8
PORTNAME=	toppler
9
PORTVERSION=	0.71
9
PORTVERSION=	1.0.2
10
CATEGORIES=	games
10
CATEGORIES=	games
11
MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
11
MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
12
MASTER_SITE_SUBDIR=	toppler
12
MASTER_SITE_SUBDIR=	toppler
Lines 23-48 Link Here
23
GNU_CONFIGURE=	yes
23
GNU_CONFIGURE=	yes
24
CONFIGURE_ENV=	SDL_CONFIG="${SDL_CONFIG}"
24
CONFIGURE_ENV=	SDL_CONFIG="${SDL_CONFIG}"
25
25
26
SCOREDIR?=	/var/games/${PORTNAME}
26
MAN6=		toppler.6
27
SCOREFILE?=	${PORTNAME}.hscr
28
27
29
pre-patch:
28
pre-patch:
30
	@${PERL} -pi -e 's|-lpthread|${PTHREAD_LIBS}|g' ${WRKSRC}/configure
29
	@${PERL} -pi -e 's|-lpthread|${PTHREAD_LIBS}|g' ${WRKSRC}/configure
31
	@find ${WRKSRC} \( -name "*.[ch]" -or -name "*.cc" \) | \
30
	@find ${WRKSRC} \( -name "*.[ch]" -or -name "*.cc" \) | \
32
		xargs ${PERL} -pi -e 's|"SDL/SDL|"SDL|g ; s|<SDL/SDL|<SDL|g'
31
		xargs ${PERL} -pi -e 's|"SDL/SDL|"SDL|g ; s|<SDL/SDL|<SDL|g'
33
32
34
post-patch:
35
	@${PERL} -pi -e 's|%SCOREDIR%|${SCOREDIR}|g;' \
36
		-e 's|%SCOREFILE%|${SCOREFILE}|g' ${WRKSRC}/menu.cc
37
38
pre-install:
39
	${MKDIR} ${SCOREDIR}
40
41
post-install:
33
post-install:
42
	${CHOWN} root:games ${PREFIX}/bin/${PORTNAME}
34
	@cd ${WRKSRC} && ${MAKE} global_highscore
43
	${CHMOD} g+s ${PREFIX}/bin/${PORTNAME}
44
	${TOUCH} ${SCOREDIR}/${SCOREFILE}
45
	${CHMOD} 664 ${SCOREDIR}/${SCOREFILE}
46
	${CHOWN} root:games ${SCOREDIR}/${SCOREFILE}
47
35
48
.include <bsd.port.mk>
36
.include <bsd.port.mk>
(-)toppler/distinfo (-1 / +1 lines)
Line 1 Link Here
1
MD5 (toppler-0.71.tar.gz) = cdaa3dd91cfa2938ffa3979ed03f7f4f
1
MD5 (toppler-1.0.2.tar.gz) = 18793ac2bec622a94e5369c645941954
(-)toppler/files/patch-configure (-11 lines)
Lines 1-11 Link Here
1
--- configure.orig	Sat Jan 19 09:55:17 2002
2
+++ configure	Sat Jan 19 09:54:37 2002
3
@@ -1167,7 +1167,7 @@
4
   rm -f conf.sdltest
5
 
6
 CPPFLAGS="$CPPFLAGS $SDL_CFLAGS"
7
-LIS="$LIBS $SDL_LIBS"
8
+LIBS="$LIBS $SDL_LIBS"
9
 
10
 echo $ac_n "checking for main in -lSDL_mixer""... $ac_c" 1>&6
11
 echo "configure:1174: checking for main in -lSDL_mixer" >&5
(-)toppler/files/patch-menu.cc (-30 lines)
Lines 1-30 Link Here
1
--- menu.cc.orig	Sat Jan 19 11:08:41 2002
2
+++ menu.cc	Sat Jan 19 11:11:09 2002
3
@@ -10,6 +10,9 @@
4
 
5
 #include <stdlib.h>
6
 
7
+#define SCOREDIR	"%SCOREDIR%"
8
+#define SCOREFILE	"%SCOREFILE%"
9
+
10
 static unsigned short menupicture, titledata;
11
 static unsigned char currentmission = 0;
12
 
13
@@ -175,7 +178,7 @@
14
 static void getscores() {
15
   char n[300];
16
 
17
-  sprintf(n, "%s/nebulous.hsc", getenv("HOME"));
18
+  sprintf(n, "%s/%s", SCOREDIR, SCOREFILE);
19
   FILE *f = fopen(n, "rb");
20
 
21
   if (f) {
22
@@ -195,7 +198,7 @@
23
 static void savescores() {
24
   char n[300];
25
 
26
-  sprintf(n, "%s/nebulous.hsc", getenv("HOME"));
27
+  sprintf(n, "%s/%s", SCOREDIR, SCOREFILE);
28
 
29
   FILE *f = fopen(n, "r+b");
30
 
(-)toppler/pkg-plist (-5 / +17 lines)
Lines 1-15 Link Here
1
bin/toppler
1
bin/toppler
2
share/toppler/abc.ttm
3
share/toppler/alarm.wav
4
share/toppler/ball1.ttm
5
share/toppler/ball2.ttm
6
share/toppler/ball3.ttm
2
share/toppler/boing.wav
7
share/toppler/boing.wav
3
share/toppler/bubbles.wav
8
share/toppler/bubbles.wav
9
share/toppler/fanfare.wav
4
share/toppler/hit.wav
10
share/toppler/hit.wav
5
share/toppler/honk.wav
11
share/toppler/honk.wav
6
share/toppler/layer1.tga
12
share/toppler/m1.ttm
7
share/toppler/layer2.tga
13
share/toppler/m2.ttm
8
share/toppler/layer3.tga
14
share/toppler/rumble.wav
9
share/toppler/nebulous.dat
15
share/toppler/score.wav
16
share/toppler/sonar.wav
10
share/toppler/splash.wav
17
share/toppler/splash.wav
11
share/toppler/swosh.wav
18
share/toppler/swoosh.wav
12
share/toppler/tap.wav
19
share/toppler/tap.wav
13
share/toppler/tick.wav
20
share/toppler/tick.wav
21
share/toppler/toppler.dat
22
share/toppler/toppler.xpm
23
share/toppler/torpedo.wav
14
share/toppler/water.wav
24
share/toppler/water.wav
25
var/toppler/toppler.hsc
15
@dirrm share/toppler
26
@dirrm share/toppler
27
@dirrm var/toppler

Return to bug 53859