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

(-)audio/gnump3d/Makefile (-5 / +4 lines)
Lines 8-26 Link Here
8
8
9
PORTNAME=	gnump3d
9
PORTNAME=	gnump3d
10
PORTVERSION=	0.9.9.7
10
PORTVERSION=	0.9.9.7
11
PORTREVISION=	1
11
CATEGORIES=	audio
12
CATEGORIES=	audio
12
MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
13
MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
13
MASTER_SITE_SUBDIR=	${PORTNAME}
14
MASTER_SITE_SUBDIR=	${PORTNAME}
14
15
15
MAINTAINER=	ports@FreeBSD.org
16
MAINTAINER=	ports@FreeBSD.org
16
17
18
MAKE_ENV=	CC="${CXX}" CFLAGS="${CXXFLAGS}" \
19
		PTHREAD_CFLAGS="${PTHREAD_CFLAGS}" \
20
		PTHREAD_LIBS="${PTHREAD_LIBS}"
17
ALL_TARGET=	freebsd
21
ALL_TARGET=	freebsd
18
22
19
MAN1=	mp3d.1 mp3d.conf.1 mp3d-top.1
23
MAN1=	mp3d.1 mp3d.conf.1 mp3d-top.1
20
21
post-patch:
22
	@${PERL} -pi -e "s,^PREFIX,#PREFIX,g ; \
23
		s,/usr/local,${PREFIX},g ; \
24
		s,-pthread,${PTHREAD_LIBS},g" ${WRKSRC}/mkfiles/freebsd
25
24
26
.include <bsd.port.mk>
25
.include <bsd.port.mk>
(-)audio/gnump3d/files/patch-freebsd (-10 / +70 lines)
Lines 1-15 Link Here
1
--- mkfiles/freebsd.orig	Mon May 27 21:23:17 2002
1
--- mkfiles/freebsd.orig	Thu May 16 18:08:35 2002
2
+++ mkfiles/freebsd	Mon May 27 21:23:31 2002
2
+++ mkfiles/freebsd	Tue May 28 02:00:05 2002
3
@@ -116,10 +116,10 @@
3
@@ -6,8 +6,8 @@
4
 	install ../mp3d.conf $(CONFIGDIR)
4
 # if you wish you may change PREFIX to be /usr/local,
5
 # for example
6
 #
7
-PREFIX = 
8
-#PREFIX = /usr/local
9
+#PREFIX = 
10
+PREFIX ?= /usr/local
11
 
12
 #
13
 #  Binary installation directory.
14
@@ -24,7 +24,7 @@
15
 #
16
 # Where we install the manpages.
17
 #
18
-MANDIR = /usr/local/man/man1
19
+MANDIR = $(PREFIX)/man/man1
20
 
21
 
22
 
23
@@ -32,12 +32,12 @@
24
 O      = o
25
 RM     = rm -f
26
 RMDIR  = rm -rf
27
-CC     = g++
28
-LIBS   = -pthread
29
+CC     ?= g++
30
+LIBS   = ${PTHREAD_LIBS}
31
 
32
 
33
-DEFAULT_CFLAGS = -I.  -D_THREAD_SAFE -D_REENTRANT -DBINARY_DIR="\"$(BINARYDIR)\"" -DSYSCONFDIR="\"$(CONFIGDIR)\"" -DVERSION="\"0.9.9.7\""
34
-CFLAGS  = $(DEFAULT_CFLAGS) -Wall -DFREEBSD=1 -DOS_TYPE="\"FreeBSD\""
35
+DEFAULT_CFLAGS = -I.  ${PTHREAD_CFLAGS} -D_REENTRANT -DBINARY_DIR="\"$(BINARYDIR)\"" -DSYSCONFDIR="\"$(CONFIGDIR)\"" -DVERSION="\"0.9.9.7\""
36
+CFLAGS  += $(DEFAULT_CFLAGS) -Wall -DFREEBSD=1 -DOS_TYPE="\"FreeBSD\""
37
 
38
 
39
 #
40
@@ -110,22 +110,22 @@
41
 #  Install the software.
42
 #
43
 install: $(PROG)
44
-	install -d $(BINARYDIR) -d $(CONFIGDIR) -d $(TEMPLATEDIR)
45
-	install ../mp3d $(BINARYDIR)
46
-	install ../contrib/stats/mp3d-top $(BINARYDIR)
47
-	install ../mp3d.conf $(CONFIGDIR)
48
+	mkdir -p $(BINARYDIR) $(CONFIGDIR) $(TEMPLATEDIR)
49
+	${BSD_INSTALL_PROGRAM} ../mp3d $(BINARYDIR)
50
+	${BSD_INSTALL_SCRIPT} ../contrib/stats/mp3d-top $(BINARYDIR)
51
+	${BSD_INSTALL_DATA} ../mp3d.conf $(CONFIGDIR)
5
 	# Default template.
52
 	# Default template.
6
 	install -d $(TEMPLATEDIR)/default
53
-	install -d $(TEMPLATEDIR)/default
7
-	cp -R ../templates/default/ $(TEMPLATEDIR)
54
-	cp -R ../templates/default/ $(TEMPLATEDIR)
8
+	cp -R ../templates/default $(TEMPLATEDIR)
55
+	mkdir -p $(TEMPLATEDIR)/default
56
+	${BSD_INSTALL_DATA} ../templates/default/* $(TEMPLATEDIR)/default
9
 	# Simple template
57
 	# Simple template
10
 	install -d $(TEMPLATEDIR)/simple 
58
-	install -d $(TEMPLATEDIR)/simple 
11
-	cp -R ../templates/simple/ $(TEMPLATEDIR)
59
-	cp -R ../templates/simple/ $(TEMPLATEDIR)
12
+	cp -R ../templates/simple $(TEMPLATEDIR)
60
-	install ../templates/README $(TEMPLATEDIR)
13
 	install ../templates/README $(TEMPLATEDIR)
61
+	mkdir -p $(TEMPLATEDIR)/simple 
62
+	${BSD_INSTALL_DATA} ../templates/simple/* $(TEMPLATEDIR)/simple
63
+	${BSD_INSTALL_DATA} ../templates/README $(TEMPLATEDIR)
14
 	# Man pages.
64
 	# Man pages.
15
 	install -d $(MANDIR)
65
-	install -d $(MANDIR)
66
-	install ../doc/mp3d.1 $(MANDIR)
67
-	install ../doc/mp3d.conf.1 $(MANDIR)
68
-	install ../doc/mp3d-top.1 $(MANDIR)
69
+	mkdir -p $(MANDIR)
70
+	${BSD_INSTALL_DATA} ../doc/mp3d.1 $(MANDIR)
71
+	${BSD_INSTALL_DATA} ../doc/mp3d.conf.1 $(MANDIR)
72
+	${BSD_INSTALL_DATA} ../doc/mp3d-top.1 $(MANDIR)
73
 
74
 
75
 #

Return to bug 38706