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
|
--- Makefile.orig Sun May 31 15:06:53 1998
+++ Makefile Sat Aug 30 01:07:19 2003
@@ -28,9 +28,9 @@
# SVR4 /usr/share/man/cat1 - 1
# Linux /usr/local/man/man1 - man
#
-LOCALLIB = /usr/local/lib
-LOCALBIN = /usr/local/bin
-LOCALMAN = /usr/local/man/cat1
+LOCALLIB = $(PREFIX)/lib
+LOCALBIN = $(PREFIX)/bin
+LOCALMAN = $(PREFIX)/man/man1
# Program to use for compressing the manpage.
# If set to 'true', no compression is applied.
@@ -41,12 +41,12 @@
# Extension of the source to be installed as manpage.
# if it is set to '1', the pre-formatted format is used,
# if it is set to 'man', the source format is used.
-#EXTENSION = man
-EXTENSION = 1
+EXTENSION = man
+#EXTENSION = 1
# Location of the GD library and include files.
-GDLIB = /usr/local/lib/libgd.a
-GDINC = /usr/local/include
+GDLIB = ${LOCALBASE}/lib/libgd.a
+GDINC = ${LOCALBASE}/include
#
# Platform selection
@@ -74,9 +74,9 @@
# If you prefer optimization of the generated code, uncomment the
# next line and comment out the -g definition.
#
-#CC = cc
+CC ?= cc
#OPTIM = -O2
-OPTIM = -g
+#OPTIM = -g
# Remove NDEBUG to include various assertion checks in the program.
#COMDEFS = -DTIME_STATS -DNDEBUG
@@ -88,6 +88,10 @@
# for the NETWARE platform.
#
+# FreeBSD
+DEFINES = -DBSD -DHA_LIBDIR="$(LOCALLIB)/http-analyze"
+PLATFORM =
+
# IRIX
#
#DEFINES = -DIRIX $(COMDEFS)
@@ -139,10 +143,10 @@
#DEFINES = -DNETWARE $(COMDEFS)
#PLATFORM =
-CFLAGS = $(OPTIM) $(PLATFORM) $(DEFINES)
+CFLAGS += $(OPTIM) $(PLATFORM) $(DEFINES)
LDFLAGS =
LINT = lint -Dunix -Xa -u
-LIBS = -lm
+LIBS = -lm -L$(LOCALLIB) -lpng
NROFF = nroff
NRFLAGS = -u1 -man
@@ -212,10 +216,12 @@
cp http-analyze.$(EXTENSION) $(LOCALMAN)/http-analyze.1
chmod 755 $(LOCALBIN)/http-analyze $(LOCALBIN)/ha-setup
chmod 444 $(LOCALMAN)/http-analyze.1
- chown bin.bin $(LOCALBIN)/http-analyze $(LOCALBIN)/ha-setup
- $(COMPRESS) $(LOCALMAN)/http-analyze.1
+ chown bin:bin $(LOCALBIN)/http-analyze $(LOCALBIN)/ha-setup
+ -mkdir -p $(PREFIX)/share/doc/http-analyze
+ cp http-analyze.pdf http-analyze.ps $(PREFIX)/share/doc/http-analyze
-mkdir -p $(LOCALLIB)/http-analyze/btn
- cp files/3D* files/TLD files/bugreport.html sample.conf $(LOCALLIB)/http-analyze/
+ cp files/3D* files/TLD files/bugreport.html rotate-httpd sample.conf \
+ $(LOCALLIB)/http-analyze/
cp files/btn/* $(LOCALLIB)/http-analyze/btn/
@echo "\nNow run 'ha-setup' to configure http-analyze for your server (Unix only).\n"
|