Ethereal-dev: Re: [ethereal-dev] Problem with --with-ucdsnmp

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Guy Harris <gharris@xxxxxxxxxxxx>
Date: Thu, 20 Jan 2000 23:51:27 -0800
> When specifying --with-ucdsnmp=DIR to configure, the
> -L${ucdsnmpdir}/lib appears after the -lsnmp in the Makefile, making
> the -L option useless (and making the compilation fail if the library
> is installed in some exotic location). So I suggest the change
> enclosed at the end of this message in aclocal.m4.

I've checked in changes to put the "-L" (and "-R") flags in LDFLAGS
rather than LIBS, so that they appear before all libraries, including
the ones in @SNMP_LIBS@ and @PCAP_LIBS@; this let me simplify the
autoconf stuff a lot, as it doesn't have to play games with AC_CHECK_LIB
to try different directories, it just does one AC_CHECK_LIB.

As part of that, I changed

			LIBS="$LIBS -L${ucdsnmpdir}/lib"

in the stuff for "--with-ucdsnmp=DIR" to

			AC_ETHEREAL_ADD_DASH_L(LDFLAGS, ${ucdsnmpdir}/lib)

which adds "-L${ucdsnmpdir}/lib" to LDFLAGS *and*, on Solaris, also adds
"-R${ucdsnmpdir}/lib", which should address that issue.