2010-06-24 18:35:21 Daniel Shahaf napisaƂ(a):
> C. Michael Pilato wrote on Wed, 23 Jun 2010 at 22:43 -0000:
> > Daniel Shahaf wrote:
> > >> -  SVN_ERR(svn_ra_svn_write_cmd(conn, pool, "get-locks", "c", path));
> > >> +  /* Figure out the repository abspath from PATH. */
> > >> +  abs_path = svn_path_url_add_component2(sess->url, path, pool);
> > >> +  SVN_ERR(svn_ra_get_path_relative_to_root(session, &abs_path,
> > >> +                                           abs_path, pool));
> > > 
> > > I think this change means that, in build.conf, libsvn_ra should have
> > > been added as a dependency to [libsvn_ra_svn].  (This patch added it only
> > > to [svnserve].)
> > > 
> > > Unless objections, I'll make this change (while also committing the
> > > ra_svn protocol bits noted on IRC and in the issue).
> > 
> > Fine with me.  (The change I made was sufficient to fix the problem I was
> > seeing in my build.)
> > 
> 
> Looking further, the patch added svn_ra_get_path_relative_to_root() to
> all network-based RA layers.  However, when I try to add libsvn_ra in
> build.conf as suggested above, I just get errors from configure/make
> about circular dependencies :-(
> 
> I'm not sure what's going on here.  But if it breaks in the future,
> hopefully this thread is going to be useful...

This revision breaks building with --enable-disallowing-of-undefined-references
option passed to `configure`.

cd subversion/libsvn_ra_svn && /usr/bin/libtool --tag=CC --silent --mode=link 
x86_64-pc-linux-gnu-gcc  -march=core2 -pipe -O2   -pthread    
-Werror=implicit-function-declaration  
-Wl,-O1,--as-needed,--gc-sections,--hash-style=gnu,--sort-common   
-L/usr/lib64/qt4  -rpath /usr/lib64 -Wl,--no-undefined -o libsvn_ra_svn-1.la  
client.lo cram.lo cyrus_auth.lo editorp.lo internal_auth.lo marshal.lo 
streams.lo version.lo ../../subversion/libsvn_delta/libsvn_delta-1.la 
../../subversion/libsvn_subr/libsvn_subr-1.la -laprutil-1 -lapr-1 -lsasl2 
.libs/client.o: In function `ra_svn_get_locks':
client.c:(.text+0x7ee): undefined reference to 
`svn_ra_get_path_relative_to_root'
collect2: ld returned 1 exit status
make: *** [subversion/libsvn_ra_svn/libsvn_ra_svn-1.la] Error 1

I suggest to create libsvn_ra_util library (similar to libsvn_fs_util).
The code of svn_ra_get_path_relative_to_root() would be moved to
svn_ra__get_path_relative_to_root(), which would be defined in libsvn_ra_util.
libsvn_ra and libsvn_ra_svn would be linked against libsvn_ra_util.
libsvn_ra_svn would use svn_ra__get_path_relative_to_root().
svn_ra_get_path_relative_to_root() would be defined in libsvn_ra and would
wrap svn_ra__get_path_relative_to_root().

-- 
Arfrever Frehtes Taifersar Arahesis

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply via email to