From: Holger P. <wb...@pa...> - 2009-04-23 02:27:35
|
Hi, David Lasker wrote on 2009-04-22 10:10:20 -0700 [Re: [BackupPC-users] best way to upgrade to and downgrade from 3.2 beta?]: > Can you point me to a reference on how to build the package for Ubuntu or > Debian? My Google foo is not strong enough to figure this out for myself. well, as Carl pointed out, you've got the 3.1.0 package as a reference. apt-get source backuppc (you'll need something like 'deb-src http://ftp.debian.org/debian lenny main' in /etc/apt/sources.list). Have a look at the diff. You'll notice that most of the changes concern paths. That means you'd probably need to look through all of the 3.2.0beta0 code (or a diff 3.1.0 -> 3.2.0beta0) for new paths that might need patching. I'll ignore that for the moment and assume the 3.1.0 patch is sufficient for creating a working 3.2.0beta0 (which may not be true). Create an empty directory somewhere to avoid confusion. Download the 3.2.0beta0 tarball into this directory. Unpack the tarball. Now, let's do some renaming. mv BackupPC-3.2.0beta0.tar.gz backuppc_3.2.0beta0.orig.tar.gz mv BackupPC-3.2.0beta0 backuppc-3.2.0beta0 Now apply the patch. cd backuppc-3.2.0beta0 zcat /path/to/backuppc_3.1.0-4.diff.gz | patch -p1 One hunk will fail, but that's irrelevant (tries to change "#!/bin/perl" to "#!/usr/bin/perl" in configure.pl, but that's been changed to "#!/usr/bin/env perl" anyway). Several hunks are applied with offsets, one with a fuzz. Remove the configure.pl.rej (just in case; not sure if the package build process minds .rej files). Next, change the version in the changelog: dch -i (edit the version into 3.2.0beta0-1; add a comment saying "New upstream release", for instance). Then, build the package: debuild -uc -us You should now have a backuppc_3.2.0beta0-1_all.deb which you can install with 'dpkg -i'. If something doesn't work, change the source, increment the version and add a changelog entry ('dch -i'), and rebuild the package ('debuild -uc -us'). Please note that I may have missed tons of things (environment variable DEBEMAIL, ~/.devscripts, ...) and that I have not in any way tested whether this package actually works without further patches. If it does, please tell us :-). Regards, Holger |