blob: 756e066b3510a0ce1a725495bf1ba1860d3a8189 (
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
|
--- Makefile.orig Fri Mar 31 08:07:54 2000
+++ Makefile Wed Jun 7 10:57:22 2000
@@ -5,16 +5,16 @@
# The path to install squirm under
-PREFIX=/usr/local/squirm
+#PREFIX=/usr/local/squirm
# The username that squid runs as (see cache_effective_user in squid.conf)
-USER=squid
+USER=$(SQUID_UID)
# The group that squid runs as (see cache_effective_group in squid.conf)
-GROUP=squid
+GROUP=$(SQUID_GID)
# The group that the root user belongs to
-ROOT_GROUP = bin
+ROOT_GROUP = wheel
# The regex library (-lgnuregex is common on FreeBSD, none for some Linux'es)
EXTRALIBS=-lgnuregex
@@ -29,26 +29,25 @@
OFILES = squirm.o main.o config.o log.o lists.o ip.o util.o
HFILES = squirm.h paths.h lists.h log.h ip.h util.h
-CC=gcc
+CC?=gcc
-OPTIMISATION=-O3
+OPTIMISATION=
BINARIES = squirm
-CFLAGS = -O3 -Wall -funroll-loops -DPREFIX=\"$(PREFIX)\"
+CFLAGS += -g -Wall -funroll-loops -DPREFIX=\"$(PREFIX)\"
#CFLAGS = -Wall -g -DPREFIX=\"$(PREFIX)\"
#CFLAGS = -Wall -g -DDEBUG
all: $(BINARIES)
install: all
- install -m 755 -o root -g $(ROOT_GROUP) -d $(PREFIX) \
- $(PREFIX)/bin
- install -m 770 -o root -g $(GROUP) -d $(PREFIX)/etc
- install -m 750 -o $(USER) -g $(GROUP) -d $(PREFIX)/logs
- install -m 660 -c -o root -g $(GROUP) squirm.conf.dist squirm.patterns.dist \
- $(PREFIX)/etc
- install -m 755 -o root -g $(ROOT_GROUP) --strip squirm $(PREFIX)/bin
+ install -m 755 -o root -g $(ROOT_GROUP) -d $(PREFIX)/squirm
+ install -m 750 -o root -g $(GROUP) -d $(PREFIX)/etc/squirm
+ install -m 750 -o $(USER) -g $(GROUP) -d $(PREFIX)/squirm/logs
+ install -m 640 -c -o root -g $(GROUP) squirm.conf.dist squirm.patterns.dist \
+ $(PREFIX)/etc/squirm
+ $(BSD_INSTALL_PROGRAM) squirm $(PREFIX)/bin
squirm.o: squirm.c $(HFILES)
$(CC) -c squirm.c $(CFLAGS)
|