Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 171624

Summary: Additional subversion script called hot-backup.py does not work out of the ebuild.
Product: Gentoo Linux Reporter: joes5532
Component: Current packagesAssignee: Paul de Vrieze (RETIRED) <pauldv>
Status: RESOLVED DUPLICATE    
Severity: normal    
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
URL: http://arcknowledge.com/gmane.comp.version-control.subversion.user/2005-02/msg00000.html
Whiteboard:
Package list:
Runtime testing required: ---

Description joes5532 2007-03-20 21:48:55 UTC
There is an extra script included with subversion that performs hot backups of a repository called hot-backup.py.  A description of it and where to find it is located here: 

http://svnbook.red-bean.com/en/1.1/ch05s03.html#svn-ch-5-sect-3.6

There are two problems with the current subversion ebuild.  First off, this script, as well as many other useful subversion scripts, are not being installed anywhere, as far as I can tell.  They are located in the tools directory of the subversion sources.  The ebuild should be modified to install these to some sensible place.

The second problem is specific to the hot-backup.py script (though it may affect some of the other ones too, but I haven't tried).  There are some macros in the hot-backup.py script that should be getting renamed, but are currently not.  This thread posting and response seem to describe the same problem in an rpm context:

http://arcknowledge.com/gmane.comp.version-control.subversion.user/2005-02/msg00000.html

Here are lines 30-34, under "Global Settings", from hot-backup.py:

# Path to svnlook utility
svnlook = "@SVN_BINDIR@/svnlook"

# Path to svnadmin utility
svnadmin = "@SVN_BINDIR@/svnadmin"

The two @SVN_BINDIR@ macros need to be renamed based on the location of the svnlook and svnadmin utilities.  In most cases it will just be /usr/bin.  If and when the ebuild installs this file somewhere, it should then take care of renaming this macro appropriately.

Reproducible: Always

Steps to Reproduce:
1. Since the tools scripts are not being installed currently, you have to manually go into /usr/portage/distfiles and copy the latest subversion-*.tar.bz2 out to some other folder.
2. Untarball the subversion sources and go into the tools/backup directory.
3. Try to run ./hot-backup.py path-to-svn-repos path-to-backup-dir and you will get an error due to the @SVN_BINDIR@ macro not being set properly.
4. To fix, do 'which svnlook' and replace the macro appropriately in both places, then re-run the script and it should work.
Comment 1 joes5532 2007-03-20 21:53:23 UTC
Did not realize, but this script, hot-backup.py, is actually being copied to /usr/bin, but it gets renamed to svn-hot-backup.  The macro problem also goes away!

*** This bug has been marked as a duplicate of bug 54304 ***

*** This bug has been marked as a duplicate of bug 54304 ***