summaryrefslogtreecommitdiff
path: root/time/globe/patches/patch-Makefile
blob: 25aee43e5f1c8b8969c8ce06db3f80e66dfe8437 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
$NetBSD: patch-Makefile,v 1.2 2016/03/30 09:17:41 jperkin Exp $

pkgsrc-ify the new Makefile

--- Makefile.orig	2014-08-11 19:13:12.000000000 +0000
+++ Makefile
@@ -1,17 +1,15 @@
 # CONFIGURE: the directory where you want the executables installed.
-BINDIR =	/usr/local/bin
+BINDIR =	${PREFIX}/bin
 
 # CONFIGURE: the directory tree where you want the man pages installed.
-MANDIR =	/usr/local/man
+MANDIR =	${PREFIX}/${PKGMANDIR}/man1
 
 # CONFIGURE: your favorite C compiler.
-CC =		cc
 
 # CONFIGURE: your favorite C flags.
 CFLAGS =	-O -ansi -pedantic -U__STRICT_ANSI__ -Wall -Wpointer-arith -Wshadow -Wcast-qual -Wcast-align -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wredundant-decls -Wno-long-long
 
 # CONFIGURE: your favorite linker flags.
-LDFLAGS =	-s
 
 all:		globe
 
@@ -19,10 +17,7 @@ globe:		globe.c
 	$(CC) $(CFLAGS) globe.c $(LDFLAGS) -o globe
 
 install:	all
-	rm -f $(BINDIR)/globe
-	cp globe $(BINDIR)
-	rm -f $(MANDIR)/man1/globe.1
-	cp globe.1 $(MANDIR)/man1
-
+	${BSD_INSTALL_PROGRAM} globe ${DESTDIR}$(BINDIR)
+	${BSD_INSTALL_MAN} globe.1 ${DESTDIR}$(MANDIR)
 clean:
 	rm -f globe a.out core