let the toolchain figure out the default header location http://bugs.gentoo.org/172209 --- Makefile +++ Makefile @@ -37,7 +37,10 @@ endif COPT_FLAGS:=-O2 -CFLAGS:=$(COPT_FLAGS) -Wall -Wunused -I$(KERNEL_DIR)/include -Iinclude/ -DIPTABLES_VERSION=\"$(IPTABLES_VERSION)\" #-g -DDEBUG #-pg # -DIPTC_DEBUG +CFLAGS:=$(COPT_FLAGS) -Wall -Wunused -Iinclude/ -DIPTABLES_VERSION=\"$(IPTABLES_VERSION)\" #-g -DDEBUG #-pg # -DIPTC_DEBUG +ifneq ($(KERNEL_DIR),) +CFLAGS += -I$(KERNEL_DIR)/include +endif ifdef NO_SHARED_LIBS CFLAGS += -DNO_SHARED_LIBS=1