You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Daniel Trebbien <dt...@gmail.com> on 2010/11/07 15:56:51 UTC

Trouble building trunk: Undefined references to svn_repos_load_fs3() and svn_repos_get_fs_build_parser3()

I am having trouble building trunk. The make process always fails when
linking libsvn_repos-1:

cd subversion/libsvn_repos && /usr/share/apr-1.0/build/libtool
--tag=CC --silent --mode=link gcc  -Wno-system-headers
-Wold-style-definition -Wdeclaration-after-statement -Wpointer-arith
-Wwrite-strings -Wshadow -ansi -Wall -Wformat=2 -Wunused
-Waggregate-return -Wstrict-prototypes -Wmissing-prototypes
-Wmissing-declarations -Wno-multichar -Wredundant-decls
-Wnested-externs -Wunreachable-code -Winline -Wno-long-long -g
-pthread -D_LARGEFILE64_SOURCE -DNE_LFS
-Werror=implicit-function-declaration  -DSVN_DEBUG -DAP_DEBUG   -rpath
/usr/local/stow/dtrebbien-subversion-HEAD/lib -Wl,--no-undefined -o
libsvn_repos-1.la  authz.lo commit.lo delta.lo deprecated.lo dump.lo
fs-wrap.lo hooks.lo load.lo log.lo node_tree.lo notify.lo
obliterate.lo replay.lo reporter.lo repos.lo rev_hunt.lo
../../subversion/libsvn_fs/libsvn_fs-1.la
../../subversion/libsvn_delta/libsvn_delta-1.la
../../subversion/libsvn_subr/libsvn_subr-1.la -laprutil-1 -lapr-1
.libs/deprecated.o: In function `svn_repos_load_fs2':
/home/daniel/projects/subversion/subversion/libsvn_repos/deprecated.c:720:
undefined reference to `svn_repos_load_fs3'
.libs/deprecated.o: In function `svn_repos_get_fs_build_parser2':
/home/daniel/projects/subversion/subversion/libsvn_repos/deprecated.c:806:
undefined reference to `svn_repos_get_fs_build_parser3'
collect2: ld returned 1 exit status
make: *** [subversion/libsvn_repos/libsvn_repos-1.la] Error 1

Is anyone else experiencing this problem?

Re: Trouble building trunk: Undefined references to svn_repos_load_fs3() and svn_repos_get_fs_build_parser3()

Posted by "noorul Islam. Kamal Malmiyoda" <no...@collab.net>.
On Nov 7, 2010, at 9:27 PM, Daniel Trebbien <dt...@gmail.com> wrote:

> I am having trouble building trunk. The make process always fails when
> linking libsvn_repos-1:
> 
> cd subversion/libsvn_repos && /usr/share/apr-1.0/build/libtool
> --tag=CC --silent --mode=link gcc  -Wno-system-headers
> -Wold-style-definition -Wdeclaration-after-statement -Wpointer-arith
> -Wwrite-strings -Wshadow -ansi -Wall -Wformat=2 -Wunused
> -Waggregate-return -Wstrict-prototypes -Wmissing-prototypes
> -Wmissing-declarations -Wno-multichar -Wredundant-decls
> -Wnested-externs -Wunreachable-code -Winline -Wno-long-long -g
> -pthread -D_LARGEFILE64_SOURCE -DNE_LFS
> -Werror=implicit-function-declaration  -DSVN_DEBUG -DAP_DEBUG   -rpath
> /usr/local/stow/dtrebbien-subversion-HEAD/lib -Wl,--no-undefined -o
> libsvn_repos-1.la  authz.lo commit.lo delta.lo deprecated.lo dump.lo
> fs-wrap.lo hooks.lo load.lo log.lo node_tree.lo notify.lo
> obliterate.lo replay.lo reporter.lo repos.lo rev_hunt.lo
> ../../subversion/libsvn_fs/libsvn_fs-1.la
> ../../subversion/libsvn_delta/libsvn_delta-1.la
> ../../subversion/libsvn_subr/libsvn_subr-1.la -laprutil-1 -lapr-1
> .libs/deprecated.o: In function `svn_repos_load_fs2':
> /home/daniel/projects/subversion/subversion/libsvn_repos/deprecated.c:720:
> undefined reference to `svn_repos_load_fs3'
> .libs/deprecated.o: In function `svn_repos_get_fs_build_parser2':
> /home/daniel/projects/subversion/subversion/libsvn_repos/deprecated.c:806:
> undefined reference to `svn_repos_get_fs_build_parser3'
> collect2: ld returned 1 exit status
> make: *** [subversion/libsvn_repos/libsvn_repos-1.la] Error 1
> 
> Is anyone else experiencing this problem?

I think I faced similar problem. I am not sure whether they are related. I had previous installation in my prefix path. I removed that and ran make which made the compilation to work without any issues.

Thanks and Regards
Noorul

Re: Trouble building trunk: Undefined references to svn_repos_load_fs3() and svn_repos_get_fs_build_parser3()

Posted by Peter Samuelson <pe...@p12n.org>.
[Daniel Trebbien]
> I tried your suggestion of removing the subversion and libsvn1
> packages (I'm running Debian Sid)

FWIW, the only package you actually had to remove in order to prevent
linker interference is libsvn-dev.  That has the *.la files, *.so
symlinks, etc. that are used at link time.

Peter

Re: Trouble building trunk: Undefined references to svn_repos_load_fs3() and svn_repos_get_fs_build_parser3()

Posted by Daniel Shahaf <d....@daniel.shahaf.name>.
Daniel Trebbien wrote on Sun, Nov 07, 2010 at 12:18:33 -0800:
> On Sun, Nov 7, 2010 at 12:04 PM, Daniel Trebbien <dt...@gmail.com> wrote:
> > Weird. It seems that `subversion/libsvn_repos/load-fs-vtable.c` was
> > the only C file in `subversion/libsvn_repos` that wasn't being
> > compiled. So, I modified the CC line that compiled
> > `subversion/libsvn_repos/log.c` to instead compile
> > `subversion/libsvn_repos/load-fs-vtable.c` and manually added
> > `load-fs-vtable.lo` to the link line that produces
> > `libsvn_repos-1.la`. That made the problem go away for now.
> 
> Two other C files were also not built:
> `subversion/svn/relocate-cmd.c` and
> `subversion/tests/libsvn_wc/utils.c`. Except for these files and
> `subversion/libsvn_repos/load-fs-vtable.c`, Subversion built just
> fine.
> 

When a C file is added, you need to re-run gen-make.py.  You can run
either ./autogen.sh or ./gen-make.py, but you don't have to ./configure.

> Am I configuring Subversion incorrectly? I am using this config line:
> ./configure --enable-maintainer-mode
> --prefix=/usr/local/stow/dtrebbien-subversion-HEAD --with-neon

Re: Trouble building trunk: Undefined references to svn_repos_load_fs3() and svn_repos_get_fs_build_parser3()

Posted by Daniel Trebbien <dt...@gmail.com>.
On Sun, Nov 7, 2010 at 12:04 PM, Daniel Trebbien <dt...@gmail.com> wrote:
> Weird. It seems that `subversion/libsvn_repos/load-fs-vtable.c` was
> the only C file in `subversion/libsvn_repos` that wasn't being
> compiled. So, I modified the CC line that compiled
> `subversion/libsvn_repos/log.c` to instead compile
> `subversion/libsvn_repos/load-fs-vtable.c` and manually added
> `load-fs-vtable.lo` to the link line that produces
> `libsvn_repos-1.la`. That made the problem go away for now.

Two other C files were also not built:
`subversion/svn/relocate-cmd.c` and
`subversion/tests/libsvn_wc/utils.c`. Except for these files and
`subversion/libsvn_repos/load-fs-vtable.c`, Subversion built just
fine.

Am I configuring Subversion incorrectly? I am using this config line:
./configure --enable-maintainer-mode
--prefix=/usr/local/stow/dtrebbien-subversion-HEAD --with-neon

Re: Trouble building trunk: Undefined references to svn_repos_load_fs3() and svn_repos_get_fs_build_parser3()

Posted by Daniel Trebbien <dt...@gmail.com>.
Weird. It seems that `subversion/libsvn_repos/load-fs-vtable.c` was
the only C file in `subversion/libsvn_repos` that wasn't being
compiled. So, I modified the CC line that compiled
`subversion/libsvn_repos/log.c` to instead compile
`subversion/libsvn_repos/load-fs-vtable.c` and manually added
`load-fs-vtable.lo` to the link line that produces
`libsvn_repos-1.la`. That made the problem go away for now.

Re: Trouble building trunk: Undefined references to svn_repos_load_fs3() and svn_repos_get_fs_build_parser3()

Posted by Stefan Sperling <st...@elego.de>.
On Sun, Nov 07, 2010 at 09:07:33AM -0800, Daniel Trebbien wrote:
> On Sun, Nov 7, 2010 at 8:01 AM, Stefan Sperling <st...@elego.de> wrote:
> > On Sun, Nov 07, 2010 at 07:56:51AM -0800, Daniel Trebbien wrote:
> >> I am having trouble building trunk. The make process always fails when
> >> linking libsvn_repos-1:
> >
> > Looks like the linker or libtool is picking up conflicting versions of
> > the same library. Try deinstalling your system subversion packages, if any.
> > Also try deleting anything within your trunk build installation prefix.
> > Also run make clean to make sure everything is recompiled.
> >
> > Stefan
> 
> I tried your suggestion of removing the subversion and libsvn1
> packages (I'm running Debian Sid), running `make clean`, and
> recompiling, but I still have the same problem.

IIRC Debian has a specially patched libtool.
Subvesion trunk uses APR's libtool, as can be seen in your transcript:

  cd subversion/libsvn_repos && /usr/share/apr-1.0/build/libtool

Maybe the problem is that APR's libtool differs from Debian's?
I don't know.  But Subversion trunk compiles fine for me (on OpenBSD),
so I suppose the problem you are seeing is either specific to your
machine or to Debian. I know there are other developers that compile
on Debian and it works for them.
One of our buildbots which is running Debian seems to be happy, too:
http://ci.apache.org/builders/svn-debian-x86_64-32%20shared%20gcc/builds/1897

If you're really stuck, try tools/dev/unix-build/, which is what I use
to compile Subversion builds for development. AFAIK it works on Debian.
It tries to avoid distribution-provided dependencies as much as possible.

Re: Trouble building trunk: Undefined references to svn_repos_load_fs3() and svn_repos_get_fs_build_parser3()

Posted by Daniel Trebbien <dt...@gmail.com>.
On Sun, Nov 7, 2010 at 8:01 AM, Stefan Sperling <st...@elego.de> wrote:
> On Sun, Nov 07, 2010 at 07:56:51AM -0800, Daniel Trebbien wrote:
>> I am having trouble building trunk. The make process always fails when
>> linking libsvn_repos-1:
>
> Looks like the linker or libtool is picking up conflicting versions of
> the same library. Try deinstalling your system subversion packages, if any.
> Also try deleting anything within your trunk build installation prefix.
> Also run make clean to make sure everything is recompiled.
>
> Stefan

I tried your suggestion of removing the subversion and libsvn1
packages (I'm running Debian Sid), running `make clean`, and
recompiling, but I still have the same problem.

Re: Trouble building trunk: Undefined references to svn_repos_load_fs3() and svn_repos_get_fs_build_parser3()

Posted by Stefan Sperling <st...@elego.de>.
On Sun, Nov 07, 2010 at 07:56:51AM -0800, Daniel Trebbien wrote:
> I am having trouble building trunk. The make process always fails when
> linking libsvn_repos-1:

Looks like the linker or libtool is picking up conflicting versions of
the same library. Try deinstalling your system subversion packages, if any.
Also try deleting anything within your trunk build installation prefix.
Also run make clean to make sure everything is recompiled.

Stefan