[Xorp-users] SNMP Compilation Error

Pavlin Radoslavov pavlin at icir.org
Thu Mar 22 16:34:36 PDT 2007


Maritess Malazarte <malazarte.maritess at gmail.com> wrote:

> Hi,
> 
> I've downloaded the latest version Xorp 1.4 and I'm trying to compile is
> using FreeBSD 6.1 as my operating system.  I modified my bootstrap's
> following entries:
> ACLOCAL=${ACLOCAL:-"aclocal15"}
> AUTOCONF=${AUTOCONF:-"autoconf259"}
> AUTOHEADER=${AUTOHEADER:-"autoheader259"}
> AUTOMAKE=${AUTOMAKE:-"automake15"}

If you only need to compile XORP, then you don't need to modify or
execute the "bootstrap" script. This script is used only if you do XORP
development.

> then I ran configure --with-snmp
> When I ran gmake, an error occurred.  Here is what was outputted.
> 
> /bin/sh ./libtool --mode=link g++  -DNETSNMP_NO_INLINE -g -W -Wall
> -Wwrite-strings -Wcast-qual -Werror -Wpointer-arith -Wcast-align
> -Woverloaded-virtual -ftemplate-depth-22   -o libnetsnmpxorp.la -rpath
> /usr/local/xorp/mibs/. -avoid-version -fPIC
> xorpevents.lo../libxipc/libxipc.la ../libxorp/libxorp.la
> ../libcomm/libcomm.la -lcrypto
> rm -fr .libs/libnetsnmpxorp.la .libs/libnetsnmpxorp.* .libs/libnetsnmpxorp.*
> g++ -shared  xorpevents.lo -Wl,--whole-archive ../libxipc/.libs/libxipc.a
> ../libxorp/.libs/libxorp.a ../libcomm/.libs/libcomm.a
> -Wl,--no-whole-archive  ../libxipc/.libs/libxipc.a
> ../libxorp/.libs/libxorp.a ../libcomm/.libs/libcomm.a -lcrypto    -lc
> -Wl,-soname -Wl,libnetsnmpxorp -o .libs/libnetsnmpxorp
> /usr/bin/ld: ../libxipc/.libs/libxipc.a(hmac_md5.o): relocation R_X86_64_32S
> can not be used when making a shared object; recompile with -fPIC
> ../libxipc/.libs/libxipc.a(hmac_md5.o): could not read symbols: Bad value
> 
> Can you tell me what I'm doing wrong here?

Please use the --enable-shared flag as well and see whether you
still have the problem:

./configure --with-snmp --enable-shared

Though, first you need to "gmake clean" the previous compilation.

BTW, what hardware/CPU are you running?
I was able to replicate the problem on AMD-64 with FreeBSD-6.2, but
I'd like to find whether the problem is specific to 64-bits
hardware.

Thanks,
Pavlin



More information about the Xorp-users mailing list