[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: SVN 1.8.x build fail

From: Philip Martin <philip.martin_at_wandisco.com>
Date: Wed, 18 Mar 2015 01:15:16 +0000

"Chen, Peter" <Peter.Chen_at_itg.com> writes:

> My configure command was:
>
> configure --prefix=/home/Svn --with-zlib=/home/lib
> --with-apr=/home/Svn --with-apr-util=/home/Svn --with-serf=/home/lib
> --with-ssl --with-sqlite=/home/Svn --disable-mod-activation
>
> Here's the last few lines when I run gmake:
>
> ../../subversion/libsvn_ra/libsvn_ra-1.la
> ../../subversion/libsvn_delta/libsvn_delta-1.la
> ../../subversion/libsvn_diff/libsvn_diff-1.la
> ../../subversion/libsvn_subr/libsvn_subr-1.la
> -L/home/local/sparc-solaris2.10/Svn/lib -laprutil-1
> -L/home/local/sparc-solaris2.10/Svn/lib -lapr-1 -L/usr/local/lib
> -liconv -lintl -L/usr/local/lib -liconv -lintl -lsocket -lz
> /home/src/subversion/sparc-solaris2.10/subversion-1.8.11/subversion/libsvn_subr/.libs/libsvn_subr-1.so:
> undefined reference to `apr_hash_do'
> collect2: ld returned 1 exit status
> gmake: *** [subversion/svn/svn] Error 1
>
> I currently have svn-1.6.x installed in a /home/bin and its libraries
> are located in /home/lib. These paths are in my $PATH and
> $LD_LIBRARY_PATH variables, respectively.
>
> I'm installing svn-1.8.x in a different file path /home/Svn/bin,
> /home/Svn/lib because we'd like users to be able to have access to
> both clients for now. APR-1.x and APR-UTIL-1.x have been installed to
> the same file paths as where I'm attempting to install svn-1.8:
> /home/Svn/bin and /home/Svn/lib
>
> I've searched the bug archives and google and haven't found any
> relevant solutions to errors w/ "undefined reference to apr_hash_do"

apr_hash_do is a symbol in libapr and it's present in 1.4.x but not in
the earlier versions. Subversion 1.6 doesn't use apr_hash_do so it can
be linked against older versions of libapr that do not provide the
symbol. I guess your Subversion 1.6 build uses an older version of
libapr. Since you now have multiple versions of libapr on your system
you have to be careful to arrange them so that the linker finds the
right version.

One way to organise this is to put things that can be shared by
Subversion 1.6 and Subversion 1.8, such as zlib, in a common dir such as
/home/lib. When you have different versions of a library for Subversion
1.6 and Subversion 1.8, such as libapr, then do not put either version
in the common dir but put both versions in directories that are specific
to the version of Subversion.

-- 
Philip Martin | Subversion Committer
WANdisco // *Non-Stop Data*
Received on 2015-03-18 02:15:46 CET

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.