Ran across this little beauty while trying to set up a mirror of the gcc
repository. (Using the 1.4.x branch)
$ svnadmin create gcc.bdb --fs-type bdb
$ cat <<'EOF' > gcc.bdb/hooks/pre-revprop-change
> #!/bin/sh
> exit 0
> EOF
$ chmod +x gcc.bdb/hooks/pre-revprop-change
$ svnsync init file://`pwd`/gcc.bdb/ svn://gcc.gnu.org/svn/gcc/
Segmentation fault (core dumped)
So, I tried it with FSFS:
$ svnadmin create gcc.fsfs
$ cat <<'EOF' > gcc.fsfs/hooks/pre-revprop-change
> #!/bin/sh
> exit 0
> EOF
$ chmod +x gcc.fsfs/hooks/pre-revprop-change
$ svnsync init file://`pwd`/gcc.fsfs/ svn://gcc.gnu.org/svn/gcc/
Copied properties for revision 0.
And it works! When I try with a recent trunk build, with
--enable-maintainer-mode, I get the following results with a bdb repository:
$ svnadmin create gcc.bdb --fs-type bdb
$ cat <<'EOF' > gcc.bdb/hooks/pre-revprop-change> #!/bin/sh
> exit 0
> EOF
$ chmod +x gcc.bdb/hooks/pre-revprop-change
$ ~/dev/svn-trunk/subversion/svnsync/svnsync init file://`pwd`/gcc.bdb/
svn://gcc.gnu.org/svn/gcc/
subversion/libsvn_fs_base/err.c:60: (apr_err=160006)
svnsync: Reference to non-existent revision 0 in filesystem
'/home/hwright/test/gcc.bdb/db'
But, when I create the repo with a trunk build, and then try it, it works:
$ ~/dev/svn-trunk/subversion/svnadmin/svnadmin create gcc.bdb --fs-type bdb
$ cat <<'EOF' > gcc.bdb/hooks/pre-revprop-change
> #!/bin/sh
> exit 0
> EOF
$ chmod +x gcc.bdb/hooks/pre-revprop-change
$ ~/dev/svn-trunk/subversion/svnsync/svnsync init file://`pwd`/gcc.bdb/
svn://gcc.gnu.org/svn/gcc/
Copied properties for revision 0.
So, it works when using a trunk-created svnadmin, and a trunk-created
svnsync. But, if the repo was created with 1.4.x, the sync won't be
initialized for bdb repositories. Was there a bug fixed in trunk
regarding creation of bdb repositories? Should that fix be backported?
-Hyrum
Received on 2008-01-16 21:16:22 CET