We recently had a difficult to solve problem installing Amanda 3.1.1
from source on Solaris 10 x86. The problem turned out to be an older
amanda library version being picked up by the 'gmake install'
(but not configure/gmake/gmake check) process from /opt/sfw
(i.e. an Amanda install that is part of the Solaris companion CD).
Forgot about that one!

Once we removed the older version and recompiled/reinstalled, things
started working.

Our questions is: why wasn't this problem picked up by our
"gmake check"?

Digging, it turns out that the libraries created under the
SOURCE directory were fine, i.e. using "ldd" on libamxfer.so
correctly shows it including "libamanda-3.1.1.so" from our
source tree. The INSTALLED libamxfer.so however, was
attempting to include "libamanda-2.5.2p1.so" from
/opt/sfw/lib. We were careful to include the same
link (-L) and runtime (-R) library locations so we weren't
expecting this.

If the gmake install process is going to relink libraries, shouldn't it
always search for AMANDA libraries in the AMANDA installation
directory first? Similar, in other words, to how the libraries
compiled under the source tree seem to search for amanda libraries
under the source tree first. If not, you're testing one thing and
then getting something that might be quite different.

Would explicitly including the install directory as part of
the runtime library path in the configure call
(e.g. LDFLAGS='-R <prefix dir>/lib/amanda') prevent this problem
in future? Is this recommened?

Thanks for any insight you can provide (well, besides the obvious
suggestion to not leave older versions of Amanda about!).

In case it helps, our configure call was:

  ./configure --with-group=sys \
  --without-amperldir \
  --with-user=amanda \
  --without-ipv6 \
  --enable-threads=solaris \
  --disable-nls \
  --disable-s3-device \
  --with-bsdtcp-security \
  --with-readline \
  --with-gnutar=/usr/sfw/bin/gtar \
  --with-gnuplot=/opt/sfw/bin/gnuplot \
  --with-index-server=thor1 \
  --prefix=${AMBASE} \
  --with-config=${AMCFG} \
  --with-configdir=${AMBASE}/etc \
  --with-tmpdir=/tmp/amanda/${AMCFG} \
  --with-gnutar-listdir=${AMBASE}/var/${AMCFG}/gnutar-lists \
  MAKE=/usr/sfw/bin/gmake \
  EGREP=/usr/sfw/bin/gegrep \
  CC=/home/compilers/SUNWspro/bin/cc \
  CPPFLAGS='-I/opt/sfw/include' \
  LDFLAGS='-L/usr/sfw/lib -L/opt/sfw/lib -R/usr/sfw/lib -R/opt/sfw/lib' \
  MTX="${AMBASE}/MTX/sbin/mtx"
  


Sean Walmsley

Reply via email to