Patchwork iptables: extensions: fix iptables extensions build error in cross-compilation environments

login
register
mail settings
Submitter Cristian Iorga
Date Jan. 16, 2013, 7:07 p.m.
Message ID <1358363255-30629-1-git-send-email-cristian.iorga@intel.com>
Download mbox | patch
Permalink /patch/212985/
State RFC
Headers show

Comments

Cristian Iorga - Jan. 16, 2013, 7:07 p.m.
libtool is properly declared and used for cross-platform
build environments

Signed-off-by: Cristian Iorga <cristian.iorga@intel.com>
---
 extensions/GNUmakefile.in |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
Pablo Neira - Jan. 28, 2013, 11:29 a.m.
Hi Cristian,

On Wed, Jan 16, 2013 at 09:07:35PM +0200, Cristian Iorga wrote:
> libtool is properly declared and used for cross-platform
> build environments

I'm hitting this error with your patch:

make[2]: se ingresa al directorio `/tmp/iptables/extensions'
  CC       libxt_AUDIT.lo
  CC       libxt_CHECKSUM.lo
  CC       libxt_CLASSIFY.lo
  CC       libxt_CONNMARK.lo
  CC       libxt_CONNSECMARK.lo
../libtool: 1552: ../libtool: ../libtool: 1552: ../libtool:
preserve_args+= --silent: not found
../libtool: 1564: ../libtool: preserve_args+= --silent: not
foundpreserve_args+= --tag CC: not found

../libtool: 1564: ../libtool: preserve_args+= --tag CC: not found
../libtool: 1: eval: base_compile+= gcc: not found
../libtool: 1: eval: base_compile+= -D_LARGEFILE_SOURCE=1: not found
../libtool: 1: eval: base_compile+= -D_LARGE_FILES: not
found../libtool: 1: eval:   CC       libxt_CT.lo
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Patch

diff --git a/extensions/GNUmakefile.in b/extensions/GNUmakefile.in
index adad4d6..befb1fb 100644
--- a/extensions/GNUmakefile.in
+++ b/extensions/GNUmakefile.in
@@ -13,6 +13,7 @@  xtlibdir     = @xtlibdir@
 
 CC                 = @CC@
 CCLD               = ${CC}
+LIBTOOL            = @LIBTOOL@
 CFLAGS             = @CFLAGS@
 CPPFLAGS           = @CPPFLAGS@
 LDFLAGS            = @LDFLAGS@
@@ -94,10 +95,10 @@  lib%.so: lib%.la
 	${AM_VERBOSE_NULL} ln -fs .libs/$@ $@
 
 lib%.la: lib%.lo
-	${AM_VERBOSE_CCLD} ../libtool ${AM_LIBTOOL_SILENT} --tag=CC --mode=link ${CCLD} ${AM_LDFLAGS} -module ${LDFLAGS} -o $@ $< ../libxtables/libxtables.la ${$*_LIBADD} -rpath ${xtlibdir}
+	${AM_VERBOSE_CCLD} ${LIBTOOL} ${AM_LIBTOOL_SILENT} --tag=CC --mode=link ${CCLD} ${AM_LDFLAGS} -module ${LDFLAGS} -o $@ $< ../libxtables/libxtables.la ${$*_LIBADD} -rpath ${xtlibdir}
 
 lib%.lo: ${srcdir}/lib%.c
-	${AM_VERBOSE_CC} ../libtool ${AM_LIBTOOL_SILENT} --tag=CC --mode=compile ${CC} ${AM_CPPFLAGS} ${AM_DEPFLAGS} ${AM_CFLAGS} -D_INIT=lib$*_init ${CFLAGS} -o $@ -c $<
+	${AM_VERBOSE_CC} ${LIBTOOL} ${AM_LIBTOOL_SILENT} --tag=CC --mode=compile ${CC} ${AM_CPPFLAGS} ${AM_DEPFLAGS} ${AM_CFLAGS} -D_INIT=lib$*_init ${CFLAGS} -o $@ -c $<
 
 libxt_NOTRACK.so: libxt_CT.so
 	${AM_VERBOSE_GEN} ln -fs $< $@