Patchwork extensions: fix linking against -lip6tc

login
register
mail settings
Submitter Mike Frysinger
Date Dec. 30, 2012, 11:11 p.m.
Message ID <1356909107-9924-1-git-send-email-vapier@gentoo.org>
Download mbox | patch
Permalink /patch/208807/
State Superseded
Headers show

Comments

Mike Frysinger - Dec. 30, 2012, 11:11 p.m.
The current build forgets to specify a path to find libip6tc which means
it either fails (if there is no libip6tc in the system), or links against
an old version (if there is one in the system).

References: https://bugs.gentoo.org/449262
Reported-by: Mike Gilbert <floppym@gentoo.org>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
---
 extensions/GNUmakefile.in | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Pablo Neira - Dec. 30, 2012, 11:38 p.m.
Hi Mike,

On Sun, Dec 30, 2012 at 06:11:47PM -0500, Mike Frysinger wrote:
> The current build forgets to specify a path to find libip6tc which means
> it either fails (if there is no libip6tc in the system), or links against
> an old version (if there is one in the system).

We already got a similar patch fix for that issue:

http://patchwork.ozlabs.org/patch/208133/

Can you give it a try and check if it also fixes the problem for you?

Thanks.
--
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
Mike Frysinger - Dec. 31, 2012, 12:51 a.m.
On Sunday 30 December 2012 18:38:28 Pablo Neira Ayuso wrote:
> Hi Mike,
> 
> On Sun, Dec 30, 2012 at 06:11:47PM -0500, Mike Frysinger wrote:
> > The current build forgets to specify a path to find libip6tc which means
> > it either fails (if there is no libip6tc in the system), or links against
> > an old version (if there is one in the system).
> 
> We already got a similar patch fix for that issue:
> 
> http://patchwork.ozlabs.org/patch/208133/
> 
> Can you give it a try and check if it also fixes the problem for you?

adding an -L path to the non-.libs/ subdir doesn't make sense when the 
existing code (the -lxtables stuff) only uses .libs/.

really the best thing would to stop grubbing around in libtool internals and 
use libtool to link considering it was used to generate the other libraries in 
the first place.
-mike

Patch

diff --git a/extensions/GNUmakefile.in b/extensions/GNUmakefile.in
index e71e3ff..a605474 100644
--- a/extensions/GNUmakefile.in
+++ b/extensions/GNUmakefile.in
@@ -101,7 +101,7 @@  libxt_state.so: libxt_conntrack.so
 	ln -fs $< $@
 
 # Need the LIBADDs in iptables/Makefile.am too for libxtables_la_LIBADD
-ip6t_NETMAP_LIBADD  = -lip6tc
+ip6t_NETMAP_LIBADD  = -L../libiptc/.libs -lip6tc
 xt_RATEEST_LIBADD   = -lm
 xt_statistic_LIBADD = -lm