Added: build_system/mdv-youri-submit/trunk/mga-signpackage
===================================================================
--- build_system/mdv-youri-submit/trunk/mga-signpackage (rev 0)
+++ build_system/mdv-youri-submit/trunk/mga-signpackage 2011-01-20 16:38:50 UTC (rev 330)
@@ -0,0 +1,29 @@
+#!/usr/bin/perl -w
+
+use strict;
+use RPM4::Sign;
+use File::Spec;
+
+sub signpackage {
+ my ($file, $name, $path) = @_;
+
+ # check if parent directory is writable
+ my $parent = (File::Spec->splitpath($file))[1];
+ die "Unsignable package, parent directory is read-only"
+ unless -w $parent;
+
+ my $sign = RPM4::Sign->new(
+ name => $name,
+ path => $path,
+ passphrase => '',
+ );
+
+ $sign->rpmssign($file)
+}
+
+if (@ARGV != 3) {
+ exit 1;
+}
+
+signpackage(@ARGV);
+
Property changes on: build_system/mdv-youri-submit/trunk/mga-signpackage
___________________________________________________________________
Added: svn:executable
+ *