iptables: build updates and fixes
The following changes since commit b8c42eca0f224a00bf55b60ded81af14a1e07da1:
libiptc: provide separate pkgconfig files (2011-12-18 02:52:32 +0100)
are available FOR REVIEW in the git repository at:
git://dev.medozas.de/iptables stable
Jan Engelhardt (6):
Update .gitignore
build: use AC_CONFIG_AUX_DIR and stash away tools Update .gitignore
build: use delayed expansion on the user-settable variables
extensions: link on libxtables and check symbols
nfnl_osf: add missing libnfnetlink_CFLAGS to compile process
.gitignore | 27 ++++----------------- configure.ac | 11 +++++++++ extensions/.gitignore | 9 +++++++ extensions/GNUmakefile.in | 56 +++++++++++++++++++------------------------- utils/Makefile.am | 3 +- 5 files changed, 51 insertions(+), 55 deletions(-) create mode 100644 extensions/.gitignore
PATCH 1/6 Update .gitignore
Only ignore these paths if they are a directory.
--- .gitignore | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-)
.gitignore +3 -3
@@ -6,9 +6,9 @@ *.oo *.so *.o -.deps +.deps/ .dirstamp -.libs +.libs/ Makefile Makefile.in
@@ -22,7 +22,7 @@ Makefile.in /include/iptables/internal.h /aclocal.m4 -/autom4te*.cache +/autom4te.cache/ /compile /config.guess /config.h*
Signature · 1 line
1.7.3.4
PATCH 2/6 build: use AC_CONFIG_AUX_DIR and stash away tools
In reply to Jan Engelhardt--- .gitignore | 12 ++---------- configure.ac | 1 + 2 files changed, 3 insertions(+), 10 deletions(-)
.gitignore +2 -10
@@ -23,16 +23,8 @@ Makefile.in /aclocal.m4 /autom4te.cache/ -/compile -/config.guess -/config.h* -/config.log -/config.status -/config.sub +/build-aux/ +/config.* /configure -/depcomp -/install-sh /libtool -/ltmain.sh -/missing /stamp-h1
configure.ac +1 -0
@@ -5,6 +5,7 @@ AC_INIT([iptables], [1.4.12.1]) libxtables_vcurrent=7 libxtables_vage=0 +AC_CONFIG_AUX_DIR([build-aux]) AC_CONFIG_HEADERS([config.h]) AC_CONFIG_MACRO_DIR([m4]) AC_PROG_INSTALL
Signature · 1 line
1.7.3.4
PATCH 3/6 Update .gitignore
In reply to Jan EngelhardtSplit off extensions/.gitignore.
--- .gitignore | 9 --------- extensions/.gitignore | 9 +++++++++ 2 files changed, 9 insertions(+), 9 deletions(-) create mode 100644 extensions/.gitignore
.gitignore +0 -9
@@ -1,9 +1,6 @@ -.*.d -.*.dd *.a *.la *.lo -*.oo *.so *.o .deps/
@@ -12,12 +9,6 @@ Makefile Makefile.in -/extensions/GNUmakefile -/extensions/initext.c -/extensions/initext?.c -/extensions/matches?.man -/extensions/targets?.man - /include/xtables.h /include/iptables/internal.h
extensions/.gitignore new file +9 -0
@@ -0,0 +1,9 @@ +.*.d +.*.dd +*.oo + +/GNUmakefile +/initext.c +/initext?.c +/matches?.man +/targets?.man
Signature · 1 line
1.7.3.4
PATCH 4/6 build: use delayed expansion on the user-settable variables
In reply to Jan Engelhardt--- extensions/GNUmakefile.in | 38 +++++++++++++++++++------------------- 1 files changed, 19 insertions(+), 19 deletions(-)
extensions/GNUmakefile.in +21 -21
@@ -1,26 +1,26 @@ # -*- Makefile -*- -top_builddir := @top_builddir@ -builddir := @builddir@ -top_srcdir := @top_srcdir@ -srcdir := @srcdir@ -ksourcedir := @ksourcedir@ -prefix := @prefix@ -exec_prefix := @exec_prefix@ -libdir := @libdir@ -libexecdir := @libexecdir@ -xtlibdir := @xtlibdir@ - -CC := @CC@ -CCLD := ${CC} -CFLAGS := @CFLAGS@ -CPPFLAGS := @CPPFLAGS@ -LDFLAGS := @LDFLAGS@ -regular_CFLAGS := @regular_CFLAGS@ -regular_CPPFLAGS := @regular_CPPFLAGS@ -kinclude_CPPFLAGS := @kinclude_CPPFLAGS@ - -AM_CFLAGS := ${regular_CFLAGS} +top_builddir = @top_builddir@ +builddir = @builddir@ +top_srcdir = @top_srcdir@ +srcdir = @srcdir@ +ksourcedir = @ksourcedir@ +prefix = @prefix@ +exec_prefix = @exec_prefix@ +libdir = @libdir@ +libexecdir = @libexecdir@ +xtlibdir = @xtlibdir@ + +CC = @CC@ +CCLD = ${CC} +CFLAGS = @CFLAGS@ +CPPFLAGS = @CPPFLAGS@ +LDFLAGS = @LDFLAGS@ +regular_CFLAGS = @regular_CFLAGS@ +regular_CPPFLAGS = @regular_CPPFLAGS@ +kinclude_CPPFLAGS = @kinclude_CPPFLAGS@ + +AM_CFLAGS = ${regular_CFLAGS} AM_CPPFLAGS = ${regular_CPPFLAGS} -I${top_builddir}/include -I${top_builddir} -I${top_srcdir}/include ${kinclude_CPPFLAGS} AM_DEPFLAGS = -Wp,-MMD,$(@D)/.$(@F).d,-MT,$@
Signature · 1 line
1.7.3.4
PATCH 5/6 extensions: link on libxtables and check symbols
In reply to Jan EngelhardtHave each extension link against libxtables.so; with this, all home symbols are known at link time and we can use ld's --no-undefined to run the check, dropping the homebrew solution.
By having libxtables.so required by extensions, package managers' automatic dependency discovery will become effective so that manual dependencies for distros with split extension packages (e.g. OpenWRT) will not be necessary anymore.
--- configure.ac | 10 ++++++++++ extensions/GNUmakefile.in | 14 +++----------- 2 files changed, 13 insertions(+), 11 deletions(-)
configure.ac +10 -0
@@ -58,6 +58,15 @@ AX_CHECK_LINKER_FLAGS([-Wl,--no-as-needed], [libiptc_LDFLAGS2="-Wl,--no-as-needed"]) AC_SUBST([libiptc_LDFLAGS2]) +AC_MSG_CHECKING([whether $LD knows -Wl,--no-undefined]) +saved_LDFLAGS="$LDFLAGS"; +LDFLAGS="-Wl,--no-undefined"; +AC_LINK_IFELSE([AC_LANG_SOURCE([int main(void) {}])], + [noundef_LDFLAGS="$LDFLAGS"; AC_MSG_RESULT([yes])], + [AC_MSG_RESULT([no])] +) +LDFLAGS="$saved_LDFLAGS"; + blacklist_modules=""; AC_CHECK_HEADERS([linux/dccp.h linux/ip_vs.h linux/magic.h linux/proc_fs.h])
@@ -99,6 +108,7 @@ pkgdatadir='${datadir}/xtables'; AC_SUBST([regular_CFLAGS]) AC_SUBST([regular_CPPFLAGS]) +AC_SUBST([noundef_LDFLAGS]) AC_SUBST([kinclude_CPPFLAGS]) AC_SUBST([kbuilddir]) AC_SUBST([ksourcedir])
extensions/GNUmakefile.in +3 -11
@@ -23,6 +23,7 @@ kinclude_CPPFLAGS = @kinclude_CPPFLAGS@ AM_CFLAGS = ${regular_CFLAGS} AM_CPPFLAGS = ${regular_CPPFLAGS} -I${top_builddir}/include -I${top_builddir} -I${top_srcdir}/include ${kinclude_CPPFLAGS} AM_DEPFLAGS = -Wp,-MMD,$(@D)/.$(@F).d,-MT,$@ +AM_LDFLAGS = @noundef_LDFLAGS@ ifeq (${V},) AM_LIBTOOL_SILENT = --silent
@@ -68,16 +69,7 @@ targets_install := .PHONY: all install clean distclean FORCE -all: ${targets} check - -check: ${targets} - @echo " CHECK unknown symbols in .so files"; \ - . ../libxtables/libxtables.la; \ - for i in lib*.so; do \ - [ "$$i" = "lib*.so" ] && continue; \ - LD_PRELOAD="$$dlname" LD_LIBRARY_PATH=../libxtables/.libs \ - ldd -r $$i 2>&1 >/dev/null; \ - done; +all: ${targets} install: ${targets_install} @mkdir -p "${DESTDIR}${xtlibdir}";
@@ -99,7 +91,7 @@ init%.o: init%.c # Shared libraries # lib%.so: lib%.oo - ${AM_VERBOSE_CCLD} ${CCLD} ${AM_LDFLAGS} -shared ${LDFLAGS} -o $@ $< ${$*_LIBADD}; + ${AM_VERBOSE_CCLD} ${CCLD} ${AM_LDFLAGS} -shared ${LDFLAGS} -o $@ $< -L../libxtables/.libs -lxtables ${$*_LIBADD}; lib%.oo: ${srcdir}/lib%.c ${AM_VERBOSE_CC} ${CC} ${AM_CPPFLAGS} ${AM_DEPFLAGS} ${AM_CFLAGS} -D_INIT=lib$*_init -DPIC -fPIC ${CFLAGS} -o $@ -c $<;
Signature · 1 line
1.7.3.4
PATCH 6/6 nfnl_osf: add missing libnfnetlink_CFLAGS to compile process
In reply to Jan Engelhardt--- utils/Makefile.am | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
utils/Makefile.am +2 -1
@@ -1,7 +1,8 @@ # -*- Makefile -*- AM_CFLAGS = ${regular_CFLAGS} -AM_CPPFLAGS = ${regular_CPPFLAGS} -I${top_builddir}/include -I${top_srcdir}/include +AM_CPPFLAGS = ${regular_CPPFLAGS} -I${top_builddir}/include \ + -I${top_srcdir}/include ${libnfnetlink_CFLAGS} sbin_PROGRAMS = nfnl_osf pkgdata_DATA = pf.os
Signature · 1 line
1.7.3.4
Pablo Neira Ayuso
maintainerQuoted 7 lines · Jan Engelhardt
The following changes since commit
b8c42eca0f224a00bf55b60ded81af14a1e07da1:
libiptc: provide separate pkgconfig files (2011-12-18 02:52:32 +0100)are available FOR REVIEW in the git repository at:
git://dev.medozas.de/iptablesstable
Quoted 7 lines
Jan Engelhardt (6):
Update .gitignore
build: useAC_CONFIG_AUX_DIRand stash away tools Update .gitignore
build: use delayed expansion on the user-settable variables
extensions: link on libxtables and check symbols
nfnl_osf: add missinglibnfnetlink_CFLAGSto compile process
No objections regarding this patchset.
Only thing is that I'd like to reduce the changes on the -stable branch to the strictly neccessary.
This is the only way to reduce the chances that someone comes and say that we have broken something in -stable.
Would you be OK if this goes to master instead?
Quoted 10 lines · Pablo Neira Ayuso
Quoted 7 lines
Jan Engelhardt (6):
Update .gitignore
build: useAC_CONFIG_AUX_DIRand stash away tools Update .gitignore
build: use delayed expansion on the user-settable variables
extensions: link on libxtables and check symbols
nfnl_osf: add missinglibnfnetlink_CFLAGSto compile processNo objections regarding this patchset.
Quoted 7 lines
Only thing is that I'd like to reduce the changes on the -stable branch to the strictly neccessary.
This is the only way to reduce the chances that someone comes and say that we have broken something in -stable.
Would you be OK if this goes to master instead?
I will cherry out nfnl_osf: for stable, and move the other to master.