diff --exclude='config.*' -ur sbuild-0.57.0/bin/sbuild sbuild-0.57.0-tabbott/bin/sbuild
--- sbuild-0.57.0/bin/sbuild	2008-01-01 06:39:56.000000000 -0500
+++ sbuild-0.57.0-tabbott/bin/sbuild	2008-03-30 00:24:54.000000000 -0400
@@ -86,6 +86,7 @@
 @main::toolchain_pkgs = ();
 $main::override_distribution = 0;
 $main::sub_task = "initialisation";
+$main::append_to_version = "";
 
 # Be verbose by default if on a tty
 if (-t STDIN && -t STDOUT && $main::verbose == 0) {
@@ -129,6 +130,7 @@
 			   $main::binNMUver ||= 1;
 		       },
 		       "binNMU=i" => \$main::binNMUver,
+		       "append-to-version=s" => \$main::append_to_version,
 		       "database=s" => \$main::database,
 		       "D|debug+" => \$conf::debug,
 		       "d|dist=s" => sub {
@@ -244,9 +246,9 @@
     {
 	my $tpkg = basename($pkgv);
 
-	if ($main::binNMU) {
+	if ($main::binNMU || $main::append_to_version) {
 	    $tpkg =~ /^([^_]+)_([^_]+)(.*)$/;
-	    $tpkg = $1 . "_" . binNMU_version($2,$main::binNMUver);
+	    $tpkg = $1 . "_" . binNMU_version($2,$main::binNMUver,$main::append_to_version);
 	    $main::binNMU_name = $tpkg;
 	    $tpkg .= $3;
 	}
@@ -606,8 +608,8 @@
 	    return 0;
 	}
 	my $tree_version = $1;
-	my $cmp_version = ($main::binNMU && -f "$dir/debian/.sbuild-binNMU-done") ?
-	    binNMU_version($version,$main::binNMUver) : $version;
+	my $cmp_version = (($main::binNMU || $main::append_to_version) && -f "$dir/debian/.sbuild-binNMU-done") ?
+	    binNMU_version($version,$main::binNMUver,$main::append_to_version) : $version;
 	if ($tree_version ne $cmp_version) {
 	    print PLOG "The unpacked source tree $dir is version ".
 		"$tree_version, not wanted $cmp_version!\n";
@@ -639,7 +641,7 @@
     }
 
     $main::pkg_fail_stage = "hack-binNMU";
-    if ($main::binNMU && ! -f "debian/.sbuild-binNMU-done") {
+    if (($main::binNMU || $main::append_to_version) && ! -f "debian/.sbuild-binNMU-done") {
 	if (open( F, "<debian/changelog" )) {
 	    my($firstline, $text);
 	    $firstline = "";
@@ -648,7 +650,7 @@
 	    close( F );
 	    $firstline =~ /^(\S+)\s+\((\S+)\)\s+([^;]+)\s*;\s*urgency=(\S+)\s*$/;
 	    my ($name, $version, $dists, $urgent) = ($1, $2, $3, $4);
-	    my $NMUversion = binNMU_version($version,$main::binNMUver);
+	    my $NMUversion = binNMU_version($version,$main::binNMUver,$main::append_to_version);
 	    chomp( my $date = `date -R` );
 	    if (!open( F, ">debian/changelog" )) {
 		print PLOG "Can't open debian/changelog for binNMU hack: $!\n";
@@ -657,9 +659,15 @@
 	    }
 	    $dists = $main::distribution;
 	    print F "$name ($NMUversion) $dists; urgency=low\n\n";
-	    print F "  * Binary-only non-maintainer upload for $main::arch; ",
+	    if ($main::append_to_version) {
+		print F "  * Append $main::append_to_version to version; no source changes\n";
+	    }
+	    if ($main::binNMU) {
+		print F "  * Binary-only non-maintainer upload for $main::arch; ",
 	    "no source changes.\n";
-	    print F "  * ", join( "    ", split( "\n", $main::binNMU )), "\n\n";
+		print F "  * ", join( "    ", split( "\n", $main::binNMU )), "\n";
+	    }
+	    print F "\n";
 	    print F " -- $conf::maintainer_name  $date\n\n";
 
 	    print F $firstline, $text;
@@ -799,7 +807,8 @@
 	}
 
 	$changes = "${pkg}_".
-	    ($main::binNMU ? binNMU_version($sversion,$main::binNMUver) : $sversion).
+	    (($main::binNMU || $main::append_to_version) ? 
+	     binNMU_version($sversion,$main::binNMUver,$main::append_to_version) : $sversion).
 	    "_$main::arch.changes";
 	my @cfiles;
 	if (-r "$main::chroot_build_dir/$changes") {
@@ -2470,6 +2479,8 @@
     if (open( F, ">>$f" )) {
 	foreach $job (@npkgs) {
 	    next if grep( /^\Q$job\E\s/, @pkgs );
+            # This is not correctly handled with --append-to-version
+	    # because I'm not sure what the line below should look like.
 	    if (not defined $main::binNMUver) {
 		print F "$job $main::distribution\n";
 	    } else {
diff --exclude='config.*' -ur sbuild-0.57.0/lib/Sbuild.pm sbuild-0.57.0-tabbott/lib/Sbuild.pm
--- sbuild-0.57.0/lib/Sbuild.pm	2008-01-01 06:39:56.000000000 -0500
+++ sbuild-0.57.0-tabbott/lib/Sbuild.pm	2008-03-29 22:24:11.000000000 -0400
@@ -169,8 +169,12 @@
 sub binNMU_version {
 	my $v = shift;
 	my $binNMUver = shift;
-
-	return "$v+b$binNMUver";
+	my $append_to_version = shift;
+	if ($binNMUver) {
+	    return "$v${append_to_version}+b$binNMUver";
+	} else {
+	    return "$v${append_to_version}";
+	}
 }
 
 1;
diff --exclude='config.*' -ur sbuild-0.57.0/man/sbuild.1.in sbuild-0.57.0-tabbott/man/sbuild.1.in
--- sbuild-0.57.0/man/sbuild.1.in	2008-01-01 06:39:56.000000000 -0500
+++ sbuild-0.57.0-tabbott/man/sbuild.1.in	2008-03-29 23:54:13.000000000 -0400
@@ -150,14 +150,22 @@
 .IR "\-\-make\-binNMU=<entry>"
 With this option, \fBsbuild\fR will create a new changelog entry in
 debian/changelog of every package built. The version number will be in the
-format for binary-only NMUs (three dotted parts in the Debian revision); the
-maintainer is set to the maintainer name configured for \fBsbuild\fR. The
-\fIentry\fR parameter will be used as a changelog entry after a fixed one
-\[lq]Binary-only non-maintainer upload for ARCH -- no source
-changes\[rq]. Please note that the versions in the \fIpackage-to-build\fR
-arguments still have to be the unmodified (non-NMU ones) so that sources can be
-found. The version number in log files and mails will be modified by
-\fBsbuild\fR automatically.
+format for binary-only NMUs (ending with +b<number>); the maintainer is set to
+the maintainer name configured for \fBsbuild\fR. The \fIentry\fR parameter will
+be used as a changelog entry after a fixed one \[lq]Binary-only non-maintainer
+upload for ARCH -- no source changes\[rq]. Please note that the versions in the
+\fIpackage-to-build\fR arguments still have to be the unmodified (non-NMU ones)
+so that sources can be found. The version number in log files and mails will be
+modified by \fBsbuild\fR automatically.
+.IR "\-\-binNMU=<number>"
+This option sets the number in the Debian revision added by --make-binNMU.  The
+default is 1.
+.TP
+.IR "\-\-append\-to\-version=<string>"
+This option is similar to --make-binNMU except that it allows the user to
+specify an arbitrary string to be appended to the version number (immediately
+before the second dot in the Debian revision if --make-binNMU is also provided).
+.TP
 .SH ENVIRONMENT VARIABLES
 The following environment variables are used by \fBsbuild\fR:
 .IP "HOME"
