summaryrefslogtreecommitdiff
path: root/graphics/xfractint/files/patch-aa
blob: fc842b80f84d2ca9c4502f601e968f304cf485f3 (plain) (blame)
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
--- Makefile.orig	Sun Sep 12 10:32:16 1999
+++ Makefile	Tue Oct 12 20:41:38 1999
@@ -2,11 +2,11 @@
 # SRCDIR should be a path to the directory that will hold fractint.hlp
 # You will have to copy fractint.hlp to SRCDIR and make it world readable.
 # SRCDIR should also hold the .par, .frm, etc. files
-SRCDIR =  /usr/src/xfractint
+SRCDIR =  ${PREFIX}/share/fractint
 # BINDIR is where you put your X11 binaries
-BINDIR = /usr/X11R6/bin
+BINDIR = ${PREFIX}/bin
 # MANDIR is where you put your chapter 1 man pages
-MANDIR = /usr/X11R6/man/man1
+MANDIR = ${PREFIX}/man/man1
 
 NOBSTRING =
 HAVESTRI =
@@ -51,7 +51,7 @@
 #For Solaris, use CFLAGS = -I. -I/usr/openwin/include $(DEFINES) -g
 
 #CFLAGS = -I. -D_CONST $(DEFINES)
-CFLAGS = -I. $(DEFINES) -g -DBIG_ANSI_C -DLINUX 
+CFLAGS += -I. $(DEFINES) -DBIG_ANSI_C -I${X11BASE}/include
 
 # Gcc is often the only compiler that works for this
 # For HPUX, use CC = cc -Aa -D_HPUX_SOURCE
@@ -60,7 +60,7 @@
 # For Sun Solaris 2.x w/SparcCompilerC (cc), use CC = cc.
 # For Sun Solaris 2.x w/GNU gcc, use CC = gcc
 #CC = gcc
-CC = cc
+CC ?= cc
 
 # For HPUX, use LIBS = -L/usr/lib/X11R4 -lX11 -lm -lcurses -ltermcap
 # For AIX or OSF/1, add -lbsd
@@ -68,8 +68,8 @@
 # For Apollo, change -lX11 to -L/usr/X11/libX11
 # For Solaris, add -L/usr/openwin/lib
 # For Linux, use  
-LIBS = -L/usr/X11R6/lib -lX11 -lm -lncurses -ltermcap
-#LIBS = -L/usr/X11R6/lib -lX11 -lm -lcurses -ltermcap
+#LIBS = -L/usr/X11R6/lib -lX11 -lm -lncurses -ltermcap
+LIBS = -L${X11BASE}/lib -lX11 -lm -lcurses -ltermcap
 #LIBS = -lX11 -lm -lcurses -ltermcap
 
 # HPUX fixes thanks to David Allport, Bill Broadley, and R. Lloyd.
@@ -166,6 +166,8 @@
 .SUFFIXES:
 .SUFFIXES: .o .c .s .h
 
+all:	xfractint
+
 xfractint: fractint.hlp .WAIT $(OBJS)
 	$(CC) -o xfractint $(CFLAGS) $(OBJS) $(LIBS)
 #	strip xfractint
@@ -180,13 +182,14 @@
 	rm -f $(OBJS) $(HOBJS) fractint.doc fractint.hlp hc xfractint helpdefs.h
 
 install: xfractint fractint.hlp
-	cp xfractint $(BINDIR)/xfractint
-	strip $(BINDIR)/xfractint
-	chmod a+x $(BINDIR)/xfractint
-	cp fractint.hlp $(PARFILES) $(FRMFILES) $(IFSFILES) $(LFILES) $(MAPFILES) $(SRCDIR)
-	(cd $(SRCDIR); chmod a+r fractint.hlp $(PARFILES) $(FRMFILES) $(IFSFILES) $(LFILES) $(MAPFILES) )
-	cp xfractint.man $(MANDIR)/xfractint.1
-	chmod a+r $(MANDIR)/xfractint.1
+	${BSD_INSTALL_PROGRAM} xfractint $(BINDIR)/xfractint
+	if [ ! -d $(SRCDIR) ]; then \
+		echo "Making $(SRCDIR)"; \
+		${INSTALL} -d -m 555 $(SRCDIR); \
+		else true; \
+	fi;
+	${BSD_INSTALL_DATA} fractint.hlp $(PARFILES) $(FRMFILES) $(IFSFILES) $(LFILES) $(MAPFILES) $(SRCDIR)
+	${BSD_INSTALL_MAN} xfractint.man $(MANDIR)/xfractint.1
 
 fractint.hlp: hc $(HELP)
 	./hc /c