Provide script to build Ada XFRM proxy
[strongswan.git] / testing / scripts / recipes / 003_freeradius.mk
1 #!/usr/bin/make
2
3 PV = 2.2.0
4 PKG = freeradius-server-$(PV)
5 TAR = $(PKG).tar.bz2
6 SRC = ftp://ftp.freeradius.org/pub/freeradius/$(TAR)
7
8 NUM_CPUS := $(shell getconf _NPROCESSORS_ONLN)
9
10 CONFIG_OPTS = \
11 --with-raddbdir=/etc/freeradius \
12 --sysconfdir=/etc \
13 --with-logdir=/var/log/freeradius \
14 --enable-developer \
15 --with-experimental-modules
16
17 PATCHES = \
18 freeradius-eap-sim-identity \
19 freeradius-avp-size \
20 freeradius-tnc-fhh
21
22 all: install
23
24 $(TAR):
25 wget $(SRC)
26
27 .$(PKG)-unpacked: $(TAR)
28 tar xfj $(TAR)
29 @touch $@
30
31 .$(PKG)-patches-applied: .$(PKG)-unpacked
32 cd $(PKG) && cat $(addprefix ../patches/, $(PATCHES)) | patch -p1
33 @touch $@
34
35 .$(PKG)-configured: .$(PKG)-patches-applied
36 cd $(PKG) && ./configure $(CONFIG_OPTS)
37 @touch $@
38
39 .$(PKG)-built: .$(PKG)-configured
40 cd $(PKG) && make -j $(NUM_CPUS)
41 @touch $@
42
43 install: .$(PKG)-built
44 cd $(PKG) && make install