From 54ac0915d0f3055ae7977ccef3ca4b52c9930c85 Mon Sep 17 00:00:00 2001 From: Daniel Hilst <392820+dhilst@users.noreply.github.com> Date: Sat, 12 Sep 2026 14:06:24 -0300 Subject: [PATCH] fix(xcat-core): the Genesis deb version never advances past snap000000000000 Every Genesis deb the Ubuntu dep pipeline publishes is versioned 2.19.0-snap000000000000. apt never upgrades an installed xcat-genesis-base, so the channel cannot ship a Genesis fix. Release is a tracked placeholder that buildrpms.pl overwrites with the commit time. The dep job clones xcat-core only to build the Genesis debs, so buildrpms.pl never runs there and builddebs.pl reads the placeholder as an authoritative release. builddebs.pl now treats an all-zero Release as an unstamped tree and falls back to the commit time. snap_release() renders a real time, so no build ever writes that value. builddebs_release_placeholder.t covers it. The test fails on the unfixed tree with snap000000000000. Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com> --- builddebs.pl | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/builddebs.pl b/builddebs.pl index 873936b44..abf016468 100755 --- a/builddebs.pl +++ b/builddebs.pl @@ -93,9 +93,12 @@ my $VERSION = read_line("$ROOT/Version") // die "Cannot read $ROOT/Version\n"; my $EPOCH = source_date_epoch(); # A Release file, when present, is authoritative: buildrpms.pl writes one, and a # pipeline that builds both must stamp the rpms and the debs with the same release. +# The tracked file holds snap000000000000, which no build writes -- snap_release() +# renders a real time. A tree where buildrpms.pl has not run still carries it, so +# treat the placeholder as an unstamped tree and derive the release from the commit. my $FILE_RELEASE = do { my $r = read_line("$ROOT/Release"); - ($r && $r =~ /\S/) ? $r : undef; + ($r && $r =~ /\S/ && $r !~ /\Asnap0+\z/) ? $r : undef; }; my $RELEASE = $opts{release} || $FILE_RELEASE || snap_release($EPOCH); my $PKGVER = deb_version($VERSION, $RELEASE);