Hello community, here is the log from the commit of package pesign-obs-integration for openSUSE:12.3 checked in at 2013-03-05 17:29:02 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:12.3/pesign-obs-integration (Old) and /work/SRC/openSUSE:12.3/.pesign-obs-integration.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "pesign-obs-integration", Maintainer is "[email protected]" Changes: -------- --- /work/SRC/openSUSE:12.3/pesign-obs-integration/pesign-obs-integration.changes 2013-02-13 12:10:06.000000000 +0100 +++ /work/SRC/openSUSE:12.3/.pesign-obs-integration.new/pesign-obs-integration.changes 2013-03-05 17:29:04.000000000 +0100 @@ -1,0 +2,33 @@ +Tue Mar 5 08:23:48 UTC 2013 - [email protected] + +- Do not repackage debuginfo package (bnc#806637) + +------------------------------------------------------------------- +Mon Mar 4 16:08:34 UTC 2013 - [email protected] + +- Version 9 +- Add support for triggers (bnc#806737) + +------------------------------------------------------------------- +Wed Feb 20 09:16:24 UTC 2013 - [email protected] + +- Do not fail the build if %_topdir/OTHER cannot be created + +------------------------------------------------------------------- +Wed Feb 13 14:51:47 UTC 2013 - [email protected] + +- Version 8 +- Hide baselibs from post-build-checks + +------------------------------------------------------------------- +Wed Feb 13 09:34:27 UTC 2013 - [email protected] + +- Do not repackage baselibs + +------------------------------------------------------------------- +Wed Feb 13 08:28:31 UTC 2013 - [email protected] + +- Version 7 +- Fix for scriptlets with empty body + +------------------------------------------------------------------- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ pesign-obs-integration.spec ++++++ --- /var/tmp/diff_new_pack.otObkJ/_old 2013-03-05 17:29:04.000000000 +0100 +++ /var/tmp/diff_new_pack.otObkJ/_new 2013-03-05 17:29:04.000000000 +0100 @@ -15,15 +15,16 @@ # Please submit bugfixes or comments via http://bugs.opensuse.org/ # - +# norootforbuild # needssslcertforbuild + Name: pesign-obs-integration Summary: Macros and scripts to sign the kernel and bootloader License: GPL-2.0 Group: Development/Tools/Other -Version: 6.0 -Release: 0 +Version: 9.0 +Release: 0.<RELEASE15> Requires: openssl mozilla-nss-tools %ifarch %ix86 x86_64 ia64 Requires: pesign ++++++ brp-99-pesign ++++++ --- /var/tmp/diff_new_pack.otObkJ/_old 2013-03-05 17:29:04.000000000 +0100 +++ /var/tmp/diff_new_pack.otObkJ/_new 2013-03-05 17:29:04.000000000 +0100 @@ -50,7 +50,10 @@ RPM_BUILD_ROOT=/ fi -mkdir -p "$output" +if ! mkdir -p "$output"; then + echo "$0: warning: $output cannot be created, giving up" >&2 + exit 0 +fi cert=$RPM_SOURCE_DIR/_projectcert.crt if test -e "$cert"; then echo "Using signing certificate $cert" ++++++ pesign-gen-repackage-spec ++++++ --- /var/tmp/diff_new_pack.otObkJ/_old 2013-03-05 17:29:04.000000000 +0100 +++ /var/tmp/diff_new_pack.otObkJ/_new 2013-03-05 17:29:04.000000000 +0100 @@ -63,6 +63,37 @@ return @res; } +sub query_multiline_array { + my ($rpm, $tag) = @_; + my @res; + my $delim = "|||"; # XXX - dangerous + + my $format = "[$delim\\n\%{$tag}\\n]"; + open(my $fh, '-|', "rpm", "-qp", "--qf", $format, $rpm) + or die "rpm: $!\n"; + my $line = <$fh>; + return unless $line; + chomp($line); + return if $line eq "(none)"; + die "Expected \"$delim\" at beginning of rpm output, got \"$line\"" + if $line ne $delim; + my $cur = ""; + while ($line = <$fh>) { + chomp($line); + if ($line eq $delim) { + $cur = "" if $cur eq "\n"; + push(@res, $cur); + $cur = ""; + } else { + $cur .= $line . "\n"; + } + } + $cur = "" if $cur eq "\n"; + push(@res, $cur); + close($fh); + return @res; +} + sub query_single { my ($rpm, $tag) = @_; my $res; @@ -151,14 +182,30 @@ } while (my ($script, $tag) = each(%script2tag)) { - my $s = query_single($rpm, $tag); - next unless $s && $s ne "(none)"; my $interp = query_single($rpm, "${tag}prog"); + next unless $interp; + my $s = query_single($rpm, $tag); $res{$script} = { interp => $interp, script => $s, }; } + my @triggers = query_array($rpm, qw(triggertype triggerscriptprog triggerconds)); + my @triggerscripts = query_multiline_array($rpm, "triggerscripts"); + if (scalar(@triggers) != scalar(@triggerscripts)) { + die "# of %%{triggertype} tags (" . scalar(@triggers) . + ") != # of %%{triggerscripts} tags (" . scalar(@triggerscripts) + . ")"; + } + for (my $i = 0; $i < scalar(@triggers); $i++) { + $res{triggers} ||= []; + push(@{$res{triggers}}, { + type => $triggers[$i]->[0], + interp => $triggers[$i]->[1], + conds => $triggers[$i]->[2], + script => $triggerscripts[$i], + }); + } open(my $fh, '-|', "rpm", "-qp", "--changelog", $rpm) or die "rpm: $!\n"; { local $/ = undef; @@ -178,6 +225,17 @@ return $text; } +sub print_script { + my ($file, $script) = @_; + + return unless $script->{script}; + open(my $fh, '>', "$output/$file") + or die "$output/$file: $!\n"; + print $fh $script->{script}; + close($fh); + print SPEC " -f $file"; +} + sub print_package { my ($p, $is_main) = @_; @@ -211,12 +269,16 @@ for my $script (keys(%script2tag)) { next unless $p->{$script}; - my $file = "$script-$p->{name}"; - open(my $fh, '>', "$output/$file") or die "$output/$file: $!\n"; - print SPEC "\%$script -p $p->{$script}{interp} -n $p->{name} -f $file\n"; - print $fh $p->{$script}{script}; - close($fh); - + print SPEC "\%$script -p $p->{$script}{interp} -n $p->{name}"; + print_script("$script-$p->{name}", $p->{$script}); + print SPEC "\n"; + } + my $i = 0; + for my $trigger (@{$p->{triggers}}) { + print SPEC "\%trigger$trigger->{type} -p $trigger->{interp} -n $p->{name}"; + print_script("trigger$i-$p->{name}", $trigger); + print SPEC " -- $trigger->{conds}\n"; + $i++; } if ($p->{files}) { print SPEC "\%files -n $p->{name}\n"; ++++++ pesign-repackage.spec.in ++++++ --- /var/tmp/diff_new_pack.otObkJ/_old 2013-03-05 17:29:04.000000000 +0100 +++ /var/tmp/diff_new_pack.otObkJ/_new 2013-03-05 17:29:04.000000000 +0100 @@ -51,6 +51,24 @@ *.src.rpm | *.nosrc.rpm) cp "$rpm" %_srcrpmdir/ continue + ;; + # Do not repackage debuginfo packages (bnc#806637) + *-debuginfo-*.rpm | *-debugsource-*.rpm) + dir=%_rpmdir/$(rpm -qp --qf '%%{arch}' "$rpm") + mkdir -p "$dir" + cp "$rpm" "$dir" + continue + ;; + esac + # do not repackage baselibs packages + # FIXME: needs more generic test (if architecture has different + # bitness => skip) + case "$(rpm -qp --qf '%%{name}/%%{arch}' "$rpm")" in + *-32bit/x86_64 | *-32bit/s390x | *-32bit/ppc64 | \ + *-64bit/ppc | *-x86/ia64) + mkdir -p "%_topdir/OTHER" + cp "$rpm" "$_" + continue esac rpm2cpio "$rpm" | cpio -idm d=$(rpm -qp --qf '%%{disturl}' "$rpm") -- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
