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

Re: Circular library dependency under Windows?

From: Max Bowsher <maxb1_at_ukf.net>
Date: 2006-02-16 18:53:41 CET

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Peter N. Lundblad wrote:
> On Thu, 16 Feb 2006, Malcolm Rowe wrote:
>
>> On Wed, Feb 15, 2006 at 09:47:02AM -0600, kfogel@collab.net wrote:
>>> "Peter N. Lundblad" <peter@famlundblad.se> writes regarding r18462:
>>>> Hmmm, I thought such circular dependencies were not supported on
>>>> Windows...
>>> You mean having the lower-level library make calls into the
>>> higher-level library? Hmm, that's a good point. It just compiled and
>>> worked for me (Debian GNU/Linux), so I assumed there was no problem.
>>>
>> I'm not absolutely certain if circular dependencies are the reason, but my Cygwin build now fails with:
>>
>> cd subversion/libsvn_fs_fs && /bin/sh /cygdrive/d/svn/svn-objdir/libtool --tag=CC --silent --mode=link gcc -g -O2 -DSVN_DEBUG -DAP_DEBUG -Wpointer-arith -Wwrite-strings -Wshadow -rpath /usr/local/lib -o libsvn_fs_fs-1.la -no-undefined dag.lo err.lo fs.lo fs_fs.lo id.lo key-gen.lo lock.lo revs-txns.lo tree.lo ../../subversion/libsvn_delta/libsvn_delta-1.la ../../subversion/libsvn_subr/libsvn_subr-1.la /usr/lib/libaprutil-0.la -lgdbm -ldb-4.2 -lexpat -liconv /usr/lib/libapr-0.la -lresolv -lcrypt -lz
>> Creating library file: .libs/libsvn_fs_fs-1.dll.a
>> .libs/tree.o: In function `copy_helper':
>> /cygdrive/d/svn/svn-objdir/../svn-trunk/subversion/libsvn_fs_fs/tree.c:1935: undefined reference to `_svn_fs__same_p'
>> /cygdrive/d/svn/svn-objdir/../svn-trunk/subversion/libsvn_fs_fs/tree.c:1937: undefined reference to `_svn_fs_path'
>> /cygdrive/d/svn/svn-objdir/../svn-trunk/subversion/libsvn_fs_fs/tree.c:1937: undefined reference to `_svn_fs_path'
>> collect2: ld returned 1 exit status
>> make: *** [subversion/libsvn_fs_fs/libsvn_fs_fs-1.la] Error 1
>>
> Probably. Fear maxb! (See r16017:-)

*grin*

I recall being a little irked when 'svn up' broke my build :-)

>> I do notice th following section in configure that implies that Cygwin
>> is the only platform that can't do circular linkage.
>>
>> AC_MSG_CHECKING([whether to avoid circular linkage at all costs])
>> case $host in
>> *-*-cygwin*)
>> AC_MSG_RESULT([yes])
>> AC_DEFINE([SVN_AVOID_CIRCULAR_LINKAGE_AT_ALL_COSTS_HACK], 1,
>> [Define if circular linkage is not possible on this platform.])
>> ;;
>> *)
>> AC_MSG_RESULT([no])
>> ;;
>> esac
>>
>
> That long macro with a very very long name is only used in one place in
> the Swig bindings it seems.

Yes. My comprehension of the Perl bindings is inadequate to remove the
circular linkage by redesigning lots of stuff, so I opted for a kludgy,
but working solution.

Problem is, it's not suitable in all cases, because it would break
things if libsvn_swig_pl was built as a static library... which it is in
our Windows build.

Max.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Cygwin)

iD8DBQFD9LwlfFNSmcDyxYARAhuSAKClU+Cv4ZJRSExmEQNXUT8H/Fbr/ACfVVQe
0hGpZgDBJCx8IJ2nt1/2m2o=
=6rxx
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Feb 16 19:11:00 2006

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

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