blob: 147e7ab485b945af39c9e9c31c23ef7d52d66de8 (
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
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
|
diff --exclude='*~' -urN fnord-1.8.orig/fnord-conf fnord-1.8/fnord-conf
--- fnord-1.8.orig/fnord-conf 2005-03-06 22:45:55.181287400 -0500
+++ fnord-1.8/fnord-conf 2005-03-06 22:46:13.049571008 -0500
@@ -17,7 +17,7 @@
mkdir -p $dir
echo "#!/bin/sh" > $dir/run
echo "cd $webroot" >> $dir/run
-echo "exec tcpserver -u $acct -RHl localhost ${myip:-0} 80 /command/fnord-httpd 2>&1" >> $dir/run
+echo "exec tcpserver -u $acct -RHl localhost ${myip:-0} 80 /usr/bin/fnord 2>&1" >> $dir/run
chmod 755 $dir/run
# tell old daemontools that it should spawn a log process, too
diff --exclude='*~' -urN fnord-1.8.orig/httpd.c fnord-1.8/httpd.c
--- fnord-1.8.orig/httpd.c 2005-03-06 22:45:55.181287400 -0500
+++ fnord-1.8/httpd.c 2005-03-06 22:48:01.591070192 -0500
@@ -25,7 +25,9 @@
#include "scan.h"
/* uncomment the following line to enable support for CGI */
-// #define CGI
+#ifndef CGI
+# define CGI
+#endif
#ifdef CGI
/* uncomment the following line to enable support for "index.cgi"
@@ -39,7 +41,9 @@
/* uncomment the following line to enable support for autogenerated
* directory-listings for directories without index */
-/* #define DIR_LIST */
+#ifndef DIR_LIST
+# define DIR_LIST
+#endif
#ifdef DIR_LIST
/* uncomment the following line to enable support for system symlink
diff --exclude='*~' -urN fnord-1.8.orig/Makefile fnord-1.8/Makefile
--- fnord-1.8.orig/Makefile 2005-03-06 22:45:55.178287856 -0500
+++ fnord-1.8/Makefile 2005-03-06 22:50:44.729269416 -0500
@@ -1,28 +1,19 @@
-CC=gcc
-CXX=g++
-
-#LIBOWFAT=../libowfat/
-DIET=diet -Os
-
-CFLAGS=-Os -fomit-frame-pointer
-#CFLAGS=-g
+CC:=gcc
+CXX:=g++
all: fnord fnord-cgi fnord-idx
fnord: httpd
cp -p $^ $@
- -strip -R .note -R .comment $@
httpd: httpd.o libowfat.a
$(DIET) $(CC) -o $@ $^ $(CFLAGS)
fnord-cgi: httpd-cgi.o libowfat.a
$(DIET) $(CC) -o $@ $^ $(CFLAGS)
- -strip -R .note -R .comment $@
fnord-idx: httpd-idx.o libowfat.a
$(DIET) $(CC) -o $@ $^ $(CFLAGS)
- -strip -R .note -R .comment $@
libowfat.a: httpd.o buffer_1.o buffer_puts.o buffer_flush.o buffer_put.o \
buffer_putulong.o buffer_2.o buffer_putspace.o buffer_stubborn.o \
@@ -32,19 +23,19 @@
-ranlib $@
httpd.o: httpd.c
- $(DIET) $(CC) -pipe $(CFLAGS) -c $^ -DFNORD=\"fnord/$(shell head -1 CHANGES|sed 's/://')\"
+ $(DIET) $(CC) $(CFLAGS) -c $^ -DFNORD=\"fnord/$(shell head -1 CHANGES|sed 's/://')\"
httpd-cgi.o: httpd.c
- $(DIET) $(CC) -pipe $(CFLAGS) -c httpd.c -o $@ -DCGI -DFNORD=\"fnord/$(shell head -1 CHANGES|sed 's/://')\"
+ $(DIET) $(CC) $(CFLAGS) -c httpd.c -o $@ -DCGI -DFNORD=\"fnord/$(shell head -1 CHANGES|sed 's/://')\"
httpd-idx.o: httpd.c
- $(DIET) $(CC) -pipe $(CFLAGS) -c httpd.c -o $@ -DDIR_LIST -DFNORD=\"fnord/$(shell head -1 CHANGES|sed 's/://')\"
+ $(DIET) $(CC) $(CFLAGS) -c httpd.c -o $@ -DDIR_LIST -DFNORD=\"fnord/$(shell head -1 CHANGES|sed 's/://')\"
%.o: %.c
- $(DIET) $(CC) -pipe $(CFLAGS) -c $^
+ $(DIET) $(CC) $(CFLAGS) -c $^
%.o: %.cpp
- $(DIET) $(CXX) -pipe $(CFLAGS) -c $^
+ $(DIET) $(CXX) $(CFLAGS) -c $^
.PHONY: rename clean install server
server: fnord
|