summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2003-03-04 23:15:42 +0000
committerHarald Welte <laforge@gnumonks.org>2003-03-04 23:15:42 +0000
commit2354d928a6864e8753decc054873d562689577d3 (patch)
tree362dd5dacb48722f4ee68c56575c99f29d597340
parentd0ae04e7ee969882f6558f2ef8bca89a2d226e62 (diff)
make DO_IPV6 work again..
-rw-r--r--Makefile9
-rw-r--r--extensions/Makefile2
-rw-r--r--libiptc/Makefile2
3 files changed, 8 insertions, 5 deletions
diff --git a/Makefile b/Makefile
index 953c0aa1..29688bc3 100644
--- a/Makefile
+++ b/Makefile
@@ -1,6 +1,9 @@
# uncomment this to get a fully statically linked version
# NO_SHARED_LIBS = 1
+# uncomment this to disable IPv6 support
+# DO_IPV6 = 0
+
######################################################################
# YOU SHOULD NOT NEED TO TOUCH ANYTHING BELOW THIS LINE
######################################################################
@@ -25,7 +28,7 @@ RELEASE_DIR:=/tmp
# Need libc6 for this. FIXME: Should covert to autoconf.
ifeq ($(shell [ -f /usr/include/netinet/ip6.h ] && echo YES), YES)
-DO_IPV6=1
+DO_IPV6:=1
endif
COPT_FLAGS:=-O2
@@ -41,7 +44,7 @@ SH_CFLAGS:=$(CFLAGS) -fPIC
STATIC_LIBS =
STATIC6_LIBS =
LDFLAGS = -rdynamic
-LDLIBS = -ldl
+LDLIBS = -ldl -lnsl
else
DEPFILES = $(EXT_OBJS:%.o=%.d)
STATIC_LIBS = extensions/libext.a
@@ -57,7 +60,7 @@ EXTRA_INSTALLS+=$(DESTDIR)$(BINDIR)/iptables $(DESTDIR)$(MANDIR)/man8/iptables.8
EXTRAS+=iptables-save iptables-restore
EXTRA_INSTALLS+=$(DESTDIR)$(BINDIR)/iptables-save $(DESTDIR)$(BINDIR)/iptables-restore $(DESTDIR)$(MANDIR)/man8/iptables-restore.8 $(DESTDIR)$(MANDIR)/man8/iptables-save.8
-ifdef DO_IPV6
+ifeq ($(DO_IPV6), 1)
EXTRAS+=ip6tables ip6tables.o
EXTRA_INSTALLS+=$(DESTDIR)$(BINDIR)/ip6tables $(DESTDIR)$(MANDIR)/man8/ip6tables.8
EXTRAS_EXP+=ip6tables-save ip6tables-restore
diff --git a/extensions/Makefile b/extensions/Makefile
index 2513b8b6..44783cff 100644
--- a/extensions/Makefile
+++ b/extensions/Makefile
@@ -22,7 +22,7 @@ ifndef NO_SHARED_LIBS
SHARED_LIBS+=$(foreach T,$(PF_EXT_SLIB),extensions/libipt_$(T).so)
EXTRA_INSTALLS+=$(foreach T, $(PF_EXT_SLIB), $(DESTDIR)$(LIBDIR)/iptables/libipt_$(T).so)
-ifdef DO_IPV6
+ifeq ($(DO_IPV6), 1)
SHARED_LIBS+=$(foreach T,$(PF6_EXT_SLIB),extensions/libip6t_$(T).so)
EXTRA_INSTALLS+=$(foreach T, $(PF6_EXT_SLIB), $(DESTDIR)$(LIBDIR)/iptables/libip6t_$(T).so)
endif
diff --git a/libiptc/Makefile b/libiptc/Makefile
index b8a36c58..1fbebef2 100644
--- a/libiptc/Makefile
+++ b/libiptc/Makefile
@@ -13,7 +13,7 @@ EXTRA_DEPENDS+=libiptc/libip4tc.d
libiptc/libiptc.a: libiptc/libiptc.a(libiptc/libip4tc.o)
-ifdef DO_IPV6
+ifeq ($(DO_IPV6), 1)
EXTRA_DEPENDS+= libiptc/libip6tc.d
libiptc/libiptc.a: libiptc/libiptc.a(libiptc/libip6tc.o)
endif