# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
#
+use strict;
+use warnings;
package conf;
+
+use vars qw< $basedir $dbbase $transactlog $mailprog $buildd_domain >;
# defaults
$basedir ||= "/var/lib/debbuild";
$dbbase ||= "build-db";
if !-x $conf::mailprog;
package main;
-use strict;
use POSIX;
use FileHandle;
use File::Copy;
@ARGV = ( $ARGS[0] );
my $pkgs = parse_packages(0);
@ARGV = ( $ARGS[3] );
- my $pkgs = parse_packages(1);
+ $pkgs = parse_packages(1);
@ARGV = ( $ARGS[1] );
parse_quinn_diff(0);
@ARGV = ( $ARGS[2] );
my $printfmt = shift;
my $pkg = shift;
my $var = shift;
+
=pod
+
Within an format string, the following values are allowed (need to be preceded by %).
This can be combined to e.g.
wanna-build --format='wanna-build -A %a --give-back %p_%v' -A mipsel --list=failed
Text could contain further %. To start with !, use %!
=cut
+
return stringf($printfmt, (
'p' => make_fmt( $pkg->{'package'}, $pkg, $var),
'a' => make_fmt( $arch, $pkg, $var),
or die $dbh->errstr;
}
-sub lock_table()
-{
+sub lock_table {
return if $simulate;
$dbh->do('LOCK TABLE ' . table_name() .
' IN EXCLUSIVE MODE', undef) or die $dbh->errstr;
}
-sub parse_argv() {
+sub parse_argv {
# parts the array $_[0] and $_[1] and returns the sub-array (modifies the original one)
my @ret = ();
my $args = shift;
return @ret;
}
-sub parse_all_v3() {
+sub parse_all_v3 {
my $srcs = shift;
my $vars = shift;
my $db = get_all_source_info();
unless ($pkg) {
next SRCS if $pkgs->{'status'} eq 'not-for-us';
- my $logstr = "merge-v3 $vars->{'time'} ".$name."_$pkgs->{'version'} ($vars->{'arch'}, $vars->{'suite'}):";
+ my $logstr = sprintf("merge-v3 %s %s_%s (%s, %s):", $vars->{'time'}, $name, $pkgs->{'version'}, $vars->{'arch'}, $vars->{'suite'});
# does at least one binary exist in the database and is more recent - if so, we're probably just outdated, ignore the source package
for my $bin (@{$pkgs->{'binary'}}) {
}
my $logstr = "merge-v3 $vars->{'time'} ".$name."_$pkgs->{'version'}".
($pkgs->{'binnmu'} ? ";b".$pkgs->{'binnmu'} : "").
- "($vars->{'arch'}, $vars->{'suite'}, previous: $pkg->{'version'}".
+ " ($vars->{'arch'}, $vars->{'suite'}, previous: $pkg->{'version'}".
($pkg->{'binary_nmu_version'} ? ";b".$pkg->{'binary_nmu_version'} : "").
", $pkg->{'state'}):";
}
if ($pkgs->{'status'} eq 'auto-not-for-us') {
- next if isin( $pkg->{'state'}, qw(Not-For-Us Failed Failed-Removed Dep-Wait Dep-Wait-Removed));
+ next if isin( $pkg->{'state'}, qw(Not-For-Us Failed Failed-Removed Dep-Wait Dep-Wait-Removed Auto-Not-For-Us));
# if the package is currently current, the status is Installed, not not-for-us
change_state( \$pkg, "Auto-Not-For-Us" );