source: ProjectBuilder/devel/pb/contrib/updateqemu@ 283

Last change on this file since 283 was 283, checked in by Bruno Cornec, 16 years ago
  • Fix pbdistrocheck usage
  • Fix build process for older distro + add new test scripts for delivery
  • Attempt to solve the problem of the delivery variable for MakeMaker which is different depending on version (PREFIX or destdir)

(merge -r276:282 svn+ssh://bruno@svn.mondorescue.org/mondo/svn/pb/0.8.11)

  • Property svn:executable set to *
File size: 930 bytes
Line 
1#!/bin/bash
2
3(
4if [ _"$1" == _"" ]; then
5 echo "Syntax: updateqemu VM|all"
6 exit -1
7fi
8if [ _"$1" == _"all" ]; then
9 opt="`grep vmlist ~/.pbrc | grep mondorescue | cut -d= -f2 | sed 's/,/ /g'`"
10 opt64="`echo $opt | sed 's/ /_64 /g'`"
11 #opt="$opt $opt64"
12 opt="$opt64"
13else
14 opt="`echo $* | sed 's/,/ /g'`"
15fi
16
17export PBPROJ=pb
18export PBROOT=/users/bruno/pb/svn/devel
19
20for m in $opt; do
21 cat /users/bruno/pb/svn/devel/pb/contrib/pbsetupqemu /users/bruno/pb/svn/devel/pb/lib/ProjectBuilder/Distribution.pm > /tmp/pbscript
22 echo "Launching script on $m"
23 pb -m $m -a root -s /tmp/pbscript script2vm
24 pb -m $m build2vm
25 echo "Halting $m"
26 echo "/sbin/halt -p" > /tmp/pbscript
27 #pb -m $m -a root -s /tmp/pbscript script2vm
28 sleep 120
29 job=`ps auhxww | grep qemu | grep $m | grep -Ev 'grep|updateqemu' | awk '{print $2}'`
30 if [ _"$job" != _"" ]; then
31 echo "Really halting $m"
32 #kill $job
33 fi
34done
35) 2>&1 | tee /tmp/updateqemu.log
Note: See TracBrowser for help on using the repository browser.