diff options
author | James Morris <jmorris@namei.org> | 2006-05-24 16:11:58 +0000 |
---|---|---|
committer | Patrick McHardy <kaber@trash.net> | 2006-05-24 16:11:58 +0000 |
commit | c81a3f32cc0877784fb287beb5e862c74e5435eb (patch) | |
tree | 8295ad578bd34ef4546133d61973b0999cf21850 /Makefile | |
parent | 2452bafd9810e8560717f10af8e26f8a3ac4f4cf (diff) |
secmark: Add libselinux support
This patch adds the infrastructure for linking iptables against
libselinux, for use with the SECMARK target. This is enabled
by setting DO_SELINUX=1 in the build environment.
Signed-off-by: James Morris <jmorris@namei.org>
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 14 |
1 files changed, 13 insertions, 1 deletions
@@ -31,6 +31,11 @@ ifeq ($(shell [ -f /usr/include/netinet/ip6.h ] && echo YES), YES) DO_IPV6:=1 endif +# Enable linking to libselinux via enviornment 'DO_SELINUX=1' +ifndef DO_SELINUX +DO_SELINUX=0 +endif + COPT_FLAGS:=-O2 CFLAGS:=$(COPT_FLAGS) -Wall -Wunused -I$(KERNEL_DIR)/include -Iinclude/ -DIPTABLES_VERSION=\"$(IPTABLES_VERSION)\" #-g -DDEBUG #-pg # -DIPTC_DEBUG @@ -93,17 +98,24 @@ endif ifndef NO_SHARED_LIBS DEPFILES = $(SHARED_LIBS:%.so=%.d) +DEPFILES += $(SHARED_SE_LIBS:%.so=%.d) SH_CFLAGS:=$(CFLAGS) -fPIC STATIC_LIBS = STATIC6_LIBS = LDFLAGS = -rdynamic LDLIBS = -ldl -lnsl +ifeq ($(DO_SELINUX), 1) +LDLIBS += -lselinux +endif else DEPFILES = $(EXT_OBJS:%.o=%.d) STATIC_LIBS = extensions/libext.a STATIC6_LIBS = extensions/libext6.a LDFLAGS = -static -LDLIBS = +LDLIBS = +ifeq ($(DO_SELINUX), 1) +LDLIBS += -lselinux +endif endif .PHONY: default |