summaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
author/C=EU/ST=EU/CN=Jozsef Kadlecsik/emailAddress=kadlec@blackhole.kfki.hu </C=EU/ST=EU/CN=Jozsef Kadlecsik/emailAddress=kadlec@blackhole.kfki.hu>2008-07-02 12:20:18 +0000
committer/C=EU/ST=EU/CN=Jozsef Kadlecsik/emailAddress=kadlec@blackhole.kfki.hu </C=EU/ST=EU/CN=Jozsef Kadlecsik/emailAddress=kadlec@blackhole.kfki.hu>2008-07-02 12:20:18 +0000
commit633b62df0104203591d5c427f6769857571b2540 (patch)
treec30e45a92d662906a92822e63b256010fec005ef /Makefile
parentcbbb94616299ae2d897cf8a8fd8d9ebf7af41be8 (diff)
Initial ipset release with kernel modules included.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile17
1 files changed, 15 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index a3da904..253498e 100644
--- a/Makefile
+++ b/Makefile
@@ -7,6 +7,12 @@
ifndef KERNEL_DIR
KERNEL_DIR=/usr/src/linux
endif
+ifndef IP_NF_SET_MAX
+IP_NF_SET_MAX=256
+endif
+ifndef IP_NF_SET_HASHSIZE
+IP_NF_SET_HASHSIZE=1024
+endif
IPSET_VERSION:=2.3.2
@@ -21,7 +27,7 @@ IPSET_LIB_DIR:=$(LIBDIR)/ipset
RELEASE_DIR:=/tmp
COPT_FLAGS:=-O2
-CFLAGS:=$(COPT_FLAGS) -Wall -Wunused -I$(KERNEL_DIR)/include -I. # -g -DIPSET_DEBUG #-pg # -DIPTC_DEBUG
+CFLAGS:=$(COPT_FLAGS) -Wall -Wunused -Ikernel/include -I. # -g -DIPSET_DEBUG #-pg # -DIPTC_DEBUG
SH_CFLAGS:=$(CFLAGS) -fPIC
SETTYPES:=ipmap portmap macipmap iphash nethash iptree iptreemap ipporthash
@@ -31,16 +37,23 @@ INSTALL=$(DESTDIR)$(BINDIR)/ipset $(DESTDIR)$(MANDIR)/man8/ipset.8
INSTALL+=$(foreach T, $(SETTYPES), $(DESTDIR)$(LIBDIR)/ipset/libipset_$(T).so)
all: $(PROGRAMS) $(SHARED_LIBS)
+ cd kernel; make -C $(KERNEL_DIR) M=`pwd` IP_NF_SET_MAX=$(IP_NF_SET_MAX) IP_NF_SET_HASHSIZE=$(IP_NF_SET_HASHSIZE) modules
.PHONY: tests
tests:
cd tests; ./runtest.sh
-install: all $(INSTALL)
+ipset_install: all $(INSTALL)
+
+modules_install:
+ cd kernel; make -C $(KERNEL_DIR) M=`pwd` modules_install
+
+install: ipset_install modules_install
clean: $(EXTRA_CLEANS)
rm -rf $(PROGRAMS) $(SHARED_LIBS) *.o *~
+ cd kernel; make -C $(KERNEL_DIR) M=`pwd` clean
#The ipset(8) self
ipset.o: ipset.c