forked from 3proxy/3proxy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.FreeBSD
57 lines (52 loc) · 1.67 KB
/
Makefile.FreeBSD
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
#
# 3 proxy Makefile for GCC/Unix
#
# You can try to remove -DWITH_STD_MALLOC to CFLAGS to use optimized malloc
# libraries
#
# remove -DNOODBC from CFLAGS and add -lodbc to LDFLAGS to compile with ODBC
# library support. Add -DSAFESQL for poorely written ODBC library / drivers.
BUILDDIR = ../bin/
CC ?= gcc
CFLAGS = -c -O -fno-strict-aliasing -DNOODBC -DWITH_STD_MALLOC -DFD_SETSIZE=4096 -DWITH_POLL
COUT = -o
LN ?= ${CC}
LDFLAGS = -pthread -O -fno-strict-aliasing
# -lpthreads may be reuqired on some platforms instead of -pthreads
# -ldl or -lld may be required for some platforms
DCFLAGS = -fpic
DLFLAGS = -shared
DLSUFFICS = .so
LIBS =
LIBSPREFIX = -l
LIBSSUFFIX =
LNOUT = -o
EXESUFFICS =
OBJSUFFICS = .o
DEFINEOPTION = -D
COMPFILES = *~
REMOVECOMMAND = rm -f
TYPECOMMAND = cat
COMPATLIBS =
MAKEFILE = Makefile.FreeBSD
PLUGINS = StringsPlugin TrafficPlugin PCREPlugin PamAuth TransparentPlugin
include Makefile.inc
install: all
if [ ! -d /usr/local/3proxy/bin ]; then mkdir -p /usr/local/3proxy/bin/; fi
install bin/3proxy /usr/local/3proxy/bin/3proxy
install bin/mycrypt /usr/local/3proxy/bin/mycrypt
install scripts/add3proxyuser.sh /usr/local/3proxy/bin/
if [ -s /usr/local/etc/3proxy/3proxy.cfg ]; then
echo /usr/local/3proxy/3proxy.cfg already exists
else
install scripts/3proxy.cfg /usr/local/etc/3proxy/
if [ ! -d /var/log/3proxy/ ]; then
mkdir /var/log/3proxy/
fi
touch /usr/local/3proxy/passwd
touch /usr/local/3proxy/counters
touch /usr/local/3proxy/bandlimiters
echo Run /usr/local/3proxy/bin/add3proxyuser.sh to add \'admin\' user
fi
allplugins:
@list='$(PLUGINS)'; for p in $$list; do cp Makefile Makefile.var plugins/$$p; cd plugins/$$p ; make ; cd ../.. ; done