Merge branch 'stroke-counters'
[strongswan.git] / testing / scripts / recipes / 004_iptables.mk
1 #!/usr/bin/make
2
3 PV = 1.4.16.3
4 PKG = iptables-$(PV)
5 TAR = $(PKG).tar.bz2
6 SRC = http://www.netfilter.org/projects/iptables/files/$(TAR)
7
8 NUM_CPUS := $(shell getconf _NPROCESSORS_ONLN)
9
10 CONFIG_OPTS =
11
12 PATCHES = \
13 iptables-xfrm-hooks
14
15 all: install
16
17 $(TAR):
18 wget $(SRC)
19
20 .$(PKG)-unpacked: $(TAR)
21 tar xfj $(TAR)
22 @touch $@
23
24 .$(PKG)-patches-applied: .$(PKG)-unpacked
25 cd $(PKG) && cat $(addprefix ../patches/, $(PATCHES)) | patch -p1
26 @touch $@
27
28 .$(PKG)-configured: .$(PKG)-patches-applied
29 cd $(PKG) && ./configure $(CONFIG_OPTS)
30 @touch $@
31
32 .$(PKG)-built: .$(PKG)-configured
33 cd $(PKG) && make -j $(NUM_CPUS)
34 @touch $@
35
36 install: .$(PKG)-built
37 cd $(PKG) && make install