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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
|
diff -ur fortune-mod-9708/datfiles/html/Makefile fortune-mod-9708+iPhone/datfiles/html/Makefile
--- fortune-mod-9708/datfiles/html/Makefile 1997-08-28 16:41:26.000000000 +0000
+++ fortune-mod-9708+iPhone/datfiles/html/Makefile 2019-05-13 17:02:16.730565812 +0000
@@ -12,9 +12,9 @@
touch cookies-stamp
install: wcookies-stamp
- install -m 0755 -d $(WCOOKIEDIR)
+ install -m 0755 -d $(DESTDIR)/$(WCOOKIEDIR)
for i in $(WCOOKIES) ; do \
- install -m 0644 $$i $$i.dat $(WCOOKIEDIR) || exit $$? ; done
+ install -m 0644 $$i $$i.dat $(DESTDIR)/$(WCOOKIEDIR) || exit $$? ; done
clean:
rm -f wcookies-stamp *.dat
diff -ur fortune-mod-9708/datfiles/Makefile fortune-mod-9708+iPhone/datfiles/Makefile
--- fortune-mod-9708/datfiles/Makefile 1997-08-28 16:38:25.000000000 +0000
+++ fortune-mod-9708+iPhone/datfiles/Makefile 2019-05-13 16:59:36.270569714 +0000
@@ -27,11 +27,11 @@
touch cookies-stamp
install: cookies-stamp
- install -m 0755 -d $(COOKIEDIR)
+ install -m 0755 -d $(DESTDIR)/$(COOKIEDIR)
if [ $(OFFENSIVE) = 1 ] ; then cd off && $(MAKE) install ; fi
if [ $(WEB) = 1 ] ; then cd html && $(MAKE) install ; fi
for i in $(COOKIES) ; do \
- install -m 0644 $$i $$i.dat $(COOKIEDIR) || exit $? ; done
+ install -m 0644 $$i $$i.dat $(DESTDIR)/$(COOKIEDIR) || exit $? ; done
clean:
rm -f cookies-stamp *.dat
diff -ur fortune-mod-9708/datfiles/off/Makefile fortune-mod-9708+iPhone/datfiles/off/Makefile
--- fortune-mod-9708/datfiles/off/Makefile 1997-08-28 16:40:42.000000000 +0000
+++ fortune-mod-9708+iPhone/datfiles/off/Makefile 2019-05-13 17:00:22.350567181 +0000
@@ -24,9 +24,9 @@
touch rotated-stamp
install:
- install -m 0755 -d $(OCOOKIEDIR)
+ install -m 0755 -d $(DESTDIR)/$(OCOOKIEDIR)
for i in $(OCOOKIES) ; \
- do install -m 0644 $$i $$i.dat $(OCOOKIEDIR) || exit $$? ; done
+ do install -m 0644 $$i $$i.dat $(DESTDIR)/$(OCOOKIEDIR) || exit $$? ; done
clean:
rm -f ocookies-stamp rotated-stamp *.dat $(OCOOKIES_UNROTATED)
diff -ur fortune-mod-9708/fortune/fortune.c fortune-mod-9708+iPhone/fortune/fortune.c
--- fortune-mod-9708/fortune/fortune.c 1997-08-28 19:43:52.000000000 +0000
+++ fortune-mod-9708+iPhone/fortune/fortune.c 2019-05-13 17:14:25.574655062 +0000
@@ -201,6 +201,7 @@
#else
#ifdef POSIX_REGEX
+#include <regex.h>
#define RE_COMP(p) regcomp(&Re_pat, (p), REG_NOSUB)
#define BAD_COMP(f) ((f) != 0)
#define RE_EXEC(p) (regexec(&Re_pat, (p), 0, NULL, 0) == 0)
diff -ur fortune-mod-9708/Makefile fortune-mod-9708+iPhone/Makefile
--- fortune-mod-9708/Makefile 1997-08-28 19:36:15.000000000 +0000
+++ fortune-mod-9708+iPhone/Makefile 2019-05-13 17:12:56.374638626 +0000
@@ -46,7 +46,7 @@
# NB. Under Linux, the BSD regex functions are _MUCH_ faster
# than the POSIX ones, but your mileage may vary.
#
-REGEXDEFS=-DHAVE_REGEX_H -DBSD_REGEX
+REGEXDEFS=-DPOSIX_REGEX
#
# If your system's regex functions are not in its standard C library,
@@ -56,7 +56,7 @@
DEFINES=-DFORTDIR="\"$(COOKIEDIR)\"" -DOFFDIR="\"$(OCOOKIEDIR)\""
CFLAGS=-O2 $(DEFINES) -Wall -fomit-frame-pointer -pipe
-LDFLAGS=-s
+LDFLAGS=
# The above flags are used by default; the debug flags are used when make
# is called with a debug target, such as 'make debug'
@@ -124,18 +124,18 @@
OFFENSIVE=$(OFFENSIVE) WEB=$(WEB)
# Install everything
-install: install-fortune install-util install-man install-cookie
+install: install-fortune install-util install-cookie
# Install just the fortune program
install-fortune: fortune-bin
- install -m 0755 -d $(FORTDIR)
- install -m 0755 fortune/fortune $(FORTDIR)
+ install -m 0755 -d $(DESTDIR)/$(FORTDIR)
+ install -m 0755 fortune/fortune $(DESTDIR)/$(FORTDIR)
# Install just the utilities strfile and unstr
install-util: util-bin
- install -m 0755 -d $(BINDIR)
- install -m $(BINMODE) util/strfile $(BINDIR)
- install -m $(BINMODE) util/unstr $(BINDIR)
+ install -m 0755 -d $(DESTDIR)/$(BINDIR)
+ install -m $(BINMODE) util/strfile $(DESTDIR)/$(BINDIR)
+ install -m $(BINMODE) util/unstr $(DESTDIR)/$(BINDIR)
# Install all the man pages
install-man: install-fman install-uman
@@ -169,7 +169,7 @@
install-cookie: cookies-z
cd datfiles && $(MAKE) COOKIEDIR=$(COOKIEDIR) \
OCOOKIEDIR=$(OCOOKIEDIR) WCOOKIEDIR=$(WCOOKIEDIR) \
- OFFENSIVE=$(OFFENSIVE) WEB=$(WEB) install
+ OFFENSIVE=$(OFFENSIVE) WEB=$(WEB) DESTDIR=$(DESTDIR) install
clean:
for i in $(SUBDIRS) ; do (cd $$i && $(MAKE) clean); done
|