From a9ab2b2dfc2e0e701e68093c89177eac78c9110f Mon Sep 17 00:00:00 2001 From: Antoine Ginies Date: Tue, 22 Feb 2011 14:50:04 +0000 Subject: sync to prepapre 5.2 release --- build_32.sh | 16 ++++++++++++++++ build_64.sh | 16 ++++++++++++++++ mes5_X86_32.xml | 19 ++++++++++++++----- mes5_X86_64.xml | 21 ++++++++++++++------- resign_rpm_by_path.pl | 41 +++++++++++++++++++++++++++++++++++++++++ 5 files changed, 101 insertions(+), 12 deletions(-) create mode 100755 build_32.sh create mode 100755 build_64.sh create mode 100755 resign_rpm_by_path.pl diff --git a/build_32.sh b/build_32.sh new file mode 100755 index 0000000..d7904bf --- /dev/null +++ b/build_32.sh @@ -0,0 +1,16 @@ +#!/bin/sh +TAG= + +./bcd.pl mes5_X86_32.xml all copy noiso + +#cd ~/build_bcd/build/XtreemOS-2.1-${TAG}i586/i586/media/main/ +#for i in *.rpm ; do echo $i ; ~/Build/resign_with_xos_key $i ; done +./bcd.pl mes5_X86_32.xml resign + +#cd ~/Build/bcd_conf + +#cp -vf ~/Build/pieces/key/RPM-GPG-KEY-XOS ~/build_bcd/build/XtreemOS-2.1.2-${TAG}i586/i586/media/main/media_info/pubkey +#cp -vf ~/Build/pieces/key/RPM-GPG-KEY-XOS ~/build_bcd/build/XtreemOS-2.1.2-${TAG}i586/i586/media/media_info/pubkey_Main + +./bcd.pl mes5_X86_32.xml iso + diff --git a/build_64.sh b/build_64.sh new file mode 100755 index 0000000..627b25f --- /dev/null +++ b/build_64.sh @@ -0,0 +1,16 @@ +#!/bin/sh +TAG= + +./bcd.pl mes5_X86_64.xml all copy noiso + +#cd ~/build_bcd/build/XtreemOS-2.1-${TAG}i586/i586/media/main/ +#for i in *.rpm ; do echo $i ; ~/Build/resign_with_xos_key $i ; done +./bcd.pl mes5_X86_64.xml resign + +#cd ~/Build/bcd_conf + +#cp -vf ~/Build/pieces/key/RPM-GPG-KEY-XOS ~/build_bcd/build/XtreemOS-2.1.2-${TAG}i586/i586/media/main/media_info/pubkey +#cp -vf ~/Build/pieces/key/RPM-GPG-KEY-XOS ~/build_bcd/build/XtreemOS-2.1.2-${TAG}i586/i586/media/media_info/pubkey_Main + +./bcd.pl mes5_X86_64.xml iso + diff --git a/mes5_X86_32.xml b/mes5_X86_32.xml index e46f015..e635556 100644 --- a/mes5_X86_32.xml +++ b/mes5_X86_32.xml @@ -32,7 +32,7 @@ - /lib/modules/2.6.27.53-server-1mnb/modules.pcimap + /lib/modules/2.6.33.7-desktop-2mnb/modules.pcimap /usr/share/pci.ids @@ -63,7 +63,7 @@ - + + + @@ -101,9 +103,16 @@ no + + lists/server_cs52 + lists/main2 + + + lists/all + @@ -115,7 +124,7 @@ no - main2 + main main /home/builduser/PIECES/i586/release @@ -177,7 +186,7 @@ - mes5.2 + echo 1 1 MES5 diff --git a/mes5_X86_64.xml b/mes5_X86_64.xml index 2f0320a..72468c6 100644 --- a/mes5_X86_64.xml +++ b/mes5_X86_64.xml @@ -32,7 +32,7 @@ - /lib/modules/2.6.27.53-server-1mnb/modules.pcimap + /lib/modules/2.6.33.7-desktop-2mnb/modules.pcimap /usr/share/pci.ids @@ -63,18 +63,19 @@ + + + @@ -102,8 +103,14 @@ + lists/server_cs52 + + lists/main2 + + lists/all + @@ -177,7 +184,7 @@ - mes5.2 + rc4 1 1 MES5 diff --git a/resign_rpm_by_path.pl b/resign_rpm_by_path.pl new file mode 100755 index 0000000..55de765 --- /dev/null +++ b/resign_rpm_by_path.pl @@ -0,0 +1,41 @@ +#!/usr/bin/perl -w + +use strict; +use Parallel::ForkManager; +use File::Glob ':glob'; +use File::Basename; +use Expect; + + +my $NB_FORK=20; +# password file +my $pwd_file = "/home/builduser/.signature.gpg"; +my $rpmrc = "/home/builduser/.rpmrc"; +my $path = $ARGV[0]; + +$ARGV[0] or die "First arg must be a path to rpm\n"; + +my $password = `cat $pwd_file`; +my $verbose = "0" ; + +my $pm = new Parallel::ForkManager($NB_FORK); +my @list_pkg = glob("$path/*.rpm"); +my $count = @list_pkg; +print "$count transactions to do ... be patient !!!!"; +my $status = "0"; +foreach my $pkg (@list_pkg) { + $pkg or next; + my $basename_pkg = basename($pkg); + $status++; + my $pid = $pm->start and next; + print("$basename_pkg ($status/$count)\n"); + my $command = Expect->spawn("LC_ALL=C rpm --rcfile=$rpmrc --resign $pkg") or die "Couldn't start rpm: $!\n"; + $command->log_stdout($verbose); + $command->expect(20, -re, 'Enter pass phrase:' => sub { print $command $password; }); + $command->expect(undef); + $command->soft_close(); + $pm->finish; +} +print "Waiting for the end of some signature...\n"; +$pm->wait_all_children; +print "all signature are done...\n"; -- cgit v1.2.1