On 10/05/2011 06:50 PM, Bart Van Assche wrote:
> On Wed, Oct 5, 2011 at 1:57 PM, Jan Safranek <jsafr...@redhat.com
> <mailto:jsafr...@redhat.com>> wrote:
> 
>     On 10/04/2011 08:09 PM, Bart Van Assche wrote:> $ readelf -a
>     ./agent/.libs/snmpd|grep perl
>     >  0x0000000000000001 (NEEDED)             Shared library: [libperl.so]
>     >  0x000000000000000f (RPATH)              Library rpath:
>     >
>     
> [/usr/lib/perl5/5.12.3/x86_64-linux-thread-multi/CORE:/usr/local/net-snmp-master/lib]
>     >  0x000000000000001d (RUNPATH)            Library runpath:
>     >
>     
> [/usr/lib/perl5/5.12.3/x86_64-linux-thread-multi/CORE:/usr/local/net-snmp-master/lib]
> 
>     That doesn't work for me, with clean compile environment (Fedora's mock,
>     i.e. gcc in chroot), I still get the same error. Only my Makefile
>     changes make it working :(.
> 
> 
> I've had a closer look, and the patch below (that includes your patch)
> was sufficient to set the libperl path in all relevant binaries - shared
> libraries and executables, including unit tests. I'm still wondering
> whether there's a more elegant way to fix this though.

Well, libtool 2.2.6 worked well in V5-5-patches without any makefile
changes. (Nearly) the same makefiles don't work with libtool 2.4, that's
why I was asking if there is a guru around.

Jan

> 
> diff --git a/agent/Makefile.in b/agent/Makefile.in
> index 128eeca..696ba72 100644
> --- a/agent/Makefile.in
> +++ b/agent/Makefile.in
> @@ -299,7 +299,7 @@ libnetsnmpagent.$(LIB_EXTENSION)$(LIB_VERSION):   
> ${LLIBAGENTOBJS} $(USELIBS)
>         $(RANLIB) $(AGENTLIB)
>  
>  libnetsnmpmibs.$(LIB_EXTENSION)$(LIB_VERSION): ${LMIBOBJS} $(AGENTLIB)
> $(USELIBS)
> -       $(LIB_LD_CMD) $(MIBLIB) ${LMIBOBJS} $(AGENTLIB) $(USELIBS)
> @LD_NO_UNDEFINED@ $(LDFLAGS) ${LMIBLIBS} $(LIB_LD_LIBS) @AGENTLIBS@
> +       $(LIB_LD_CMD) $(MIBLIB) ${LMIBOBJS} $(AGENTLIB) $(USELIBS)
> @LD_NO_UNDEFINED@ $(LDFLAGS) ${LMIBLIBS} $(PERLLDOPTS_FOR_LIBS)
> $(LIB_LD_LIBS) @AGENTLIBS@
>         $(RANLIB) $(MIBLIB)
>  
>  agentlib: $(AGENTLIB)
> diff --git a/ltmain.sh b/ltmain.sh
> old mode 100755
> new mode 100644
> index e492218..ed1814f
> --- a/ltmain.sh
> +++ b/ltmain.sh
> @@ -8051,7 +8051,7 @@ EOF
>             elif test -n "$runpath_var"; then
>               case "$perm_rpath " in
>               *" $libdir "*) ;;
> -             *) func_apped perm_rpath " $libdir" ;;
> +             *) func_append perm_rpath " $libdir" ;;
>               esac
>             fi
>           done
> diff --git a/net-snmp-config.in <http://net-snmp-config.in>
> b/net-snmp-config.in <http://net-snmp-config.in>
> index ef17bac..7bdafe0 100644
> --- a/net-snmp-config.in <http://net-snmp-config.in>
> +++ b/net-snmp-config.in <http://net-snmp-config.in>
> @@ -183,7 +183,7 @@ else
>        echo $result
>        ;;
>      --build-command)
> -      echo "@CC@ @CFLAGS@ @DEVFLAGS@"
> +      echo "@CC@ @CFLAGS@ @DEVFLAGS@ @PERLLDOPTS_FOR_LIBS@"
>        ;;
>      #################################################### client lib
>      --libs)
> 


------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure contains a
definitive record of customers, application performance, security
threats, fraudulent activity and more. Splunk takes this data and makes
sense of it. Business sense. IT sense. Common sense.
http://p.sf.net/sfu/splunk-d2dcopy1
_______________________________________________
Net-snmp-coders mailing list
Net-snmp-coders@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to