[iptables] build: check for missing feature files

Patrick McHardy netfilter-cvslog-bounces at lists.netfilter.org
Thu Jun 5 20:08:18 CEST 2008


Gitweb:		http://git.netfilter.org/cgi-bin/gitweb.cgi?p=iptables.git;a=commit;h=2c570e76d4c627a0b0417cfa0d0f2e787a6d629d
commit 2c570e76d4c627a0b0417cfa0d0f2e787a6d629d
Author:     Jan Engelhardt <jengelh at medozas.de>
AuthorDate: Thu Jun 5 19:54:48 2008 +0200
Commit:     Patrick McHardy <kaber at trash.net>
CommitDate: Thu Jun 5 19:54:48 2008 +0200

    build: check for missing feature files
    
    linux/dccp.h is unlikely to be installed before 2.6.18 (which was
    when headers_install was introduced), and does not exist at all
    before 2.6.14. Add a compile-time check to skip compilation of
    libxt_dccp in case this was detected.
    
    Signed-off-by: Jan Engelhardt <jengelh at medozas.de>
    Signed-off-by: Patrick McHardy <kaber at trash.net>
       via  2c570e76d4c627a0b0417cfa0d0f2e787a6d629d (commit)
      from  324651944e03072cde144d41896b2e207672d0f2 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 2c570e76d4c627a0b0417cfa0d0f2e787a6d629d
Author: Jan Engelhardt <jengelh at medozas.de>
Date:   Thu Jun 5 19:54:48 2008 +0200

    build: check for missing feature files
    
    linux/dccp.h is unlikely to be installed before 2.6.18 (which was
    when headers_install was introduced), and does not exist at all
    before 2.6.14. Add a compile-time check to skip compilation of
    libxt_dccp in case this was detected.
    
    Signed-off-by: Jan Engelhardt <jengelh at medozas.de>
    Signed-off-by: Patrick McHardy <kaber at trash.net>

-----------------------------------------------------------------------

 configure.ac              |    8 ++++++++
 extensions/GNUmakefile.in |    3 +++
 2 files changed, 11 insertions(+), 0 deletions(-)
linux/dccp.h is unlikely to be installed before 2.6.18 (which was
when headers_install was introduced), and does not exist at all
before 2.6.14. Add a compile-time check to skip compilation of
libxt_dccp in case this was detected.

Signed-off-by: Jan Engelhardt <jengelh at medozas.de>
Signed-off-by: Patrick McHardy <kaber at trash.net>

diff --git a/configure.ac b/configure.ac
index e718eff..d063605 100644
--- a/configure.ac
+++ b/configure.ac
@@ -39,6 +39,14 @@ AC_ARG_ENABLE([libipq],
 	AS_HELP_STRING([--enable-libipq], [Build and install libipq]))
 
 AC_CHECK_HEADER([netinet/ip6.h], [], [AC_MSG_ERROR(but we need that for IPv6)])
+AC_CHECK_HEADER([linux/dccp.h])
+
+blacklist_modules="";
+if test "$ac_cv_header_linux_dccp_h" != "yes"; then
+	blacklist_modules="$blacklist_modules dccp";
+fi;
+AC_SUBST([blacklist_modules])
+
 AM_CONDITIONAL([ENABLE_STATIC], [test "$enable_static" == "yes"])
 AM_CONDITIONAL([ENABLE_SHARED], [test "$enable_shared" == "yes"])
 AM_CONDITIONAL([ENABLE_DEVEL], [test "$enable_devel" == "yes"])
diff --git a/extensions/GNUmakefile.in b/extensions/GNUmakefile.in
index 9419574..8d44e4e 100644
--- a/extensions/GNUmakefile.in
+++ b/extensions/GNUmakefile.in
@@ -37,6 +37,9 @@ endif
 pfx_build_mod := $(patsubst ${srcdir}/libxt_%.c,%,$(wildcard ${srcdir}/libxt_*.c))
 pf4_build_mod := $(patsubst ${srcdir}/libipt_%.c,%,$(wildcard ${srcdir}/libipt_*.c))
 pf6_build_mod := $(patsubst ${srcdir}/libip6t_%.c,%,$(wildcard ${srcdir}/libip6t_*.c))
+pfx_build_mod := $(filter-out @blacklist_modules@,${pfx_build_mod})
+pf4_build_mod := $(filter-out @blacklist_modules@,${pf4_build_mod})
+pf6_build_mod := $(filter-out @blacklist_modules@,${pf6_build_mod})
 pfx_objs      := $(patsubst %,libxt_%.o,${pfx_build_mod})
 pf4_objs      := $(patsubst %,libipt_%.o,${pf4_build_mod})
 pf6_objs      := $(patsubst %,libip6t_%.o,${pf6_build_mod})



More information about the netfilter-cvslog mailing list