Changeset 2538 in MondoRescue
- Timestamp:
- Jan 9, 2010, 4:40:44 PM (15 years ago)
- Location:
- devel
- Files:
-
- 1 deleted
- 4 edited
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
devel/mindi/Makefile.PL
r2149 r2538 8 8 DISTNAME => 'PBPKG', 9 9 VERSION => 'PBVER', 10 INST_SCRIPT => 'blib/ bin',10 INST_SCRIPT => 'blib/sbin', 11 11 INSTALLDIRS => 'perl', 12 12 PREREQ_PM => { … … 14 14 #Template => 0, 15 15 }, # e.g., Module::Name => 1.1 16 #ABSTRACT_FROM => ' bin/pb', # retrieve abstract from module16 #ABSTRACT_FROM => 'sbin/mindi', # retrieve abstract from module 17 17 AUTHOR => 'Bruno Cornec <bruno#mondorescue.org>', 18 18 EXE_FILES => [ qw( sbin/mindi sbin/mranalyze-lvm sbin/mrprepare-lvm ) ], -
devel/mindi/post-install.sh
r2149 r2538 4 4 # 5 5 6 if [ ! -f "mindi" ] ; then7 echo "Please 'cd' to the directory you have just untarred." >> /dev/stderr8 exit 19 fi10 11 6 if [ "_$PREFIX" != "_" ]; then 12 7 local=${HEAD}$PREFIX 13 8 sublocal=$PREFIX 14 9 if [ "_$CONFDIR" != "_" ]; then 15 conf=${HEAD}$CONFDIR/PBP ROJ16 subconf=$CONFDIR/PBP ROJ10 conf=${HEAD}$CONFDIR/PBPKG 11 subconf=$CONFDIR/PBPKG 17 12 else 18 13 echo "CONFDIR should be defined if PREFIX is defined" … … 22 17 local=/usr/local 23 18 sublocal=$local 24 if [ -f /usr/bin/mindi ]; then 25 echo "WARNING: /usr/bin/mindi exists. You should probably remove the mindi package !" 26 fi 27 conf=$local/etc/PBPROJ 19 conf=$local/etc/PBPKG 28 20 subconf=$conf 29 21 fi 30 22 31 23 if [ _"$CACHEDIR" = _"" ]; then 32 CACHEDIR=$local/var/cache/ mindi24 CACHEDIR=$local/var/cache/PBPKG 33 25 else 34 26 CACHEDIR=${HEAD}$CACHEDIR 35 27 fi 36 locallib=$local/share/lib 37 sublocallib="$locallib/PBPROJ" 38 39 40 if uname -a | grep Knoppix > /dev/null || [ -e "/ramdisk/usr" ] ; then 41 local=/ramdisk/usr 42 sublocal=$local 43 conf=/ramdisk/etc 44 subconf=$conf 45 export PATH=/ramdisk/usr/sbin:/ramdisk/usr/bin:/$PATH 46 fi 28 sublocalshare="$local/share/PBPKG" 29 sublocallib="$local/lib/PBPKG" 47 30 48 31 MINDIVER=PBVER … … 52 35 53 36 echo "Creating target directories ..." 54 install -m 755 -d $conf $sublocallib $ CACHEDIR37 install -m 755 -d $conf $sublocallib $sublocalshare $CACHEDIR 55 38 56 echo "Copying files ..."57 cp -af rootfs $sublocallib/mindi58 chmod 755 $sublocallib/mindi/rootfs/sbin/*59 install -m 644 msg-txt dev.tgz $sublocallib/mindi60 install -m 644 deplist.txt udev.files proliant.files $conf39 #echo "Copying files ..." 40 #cp -af rootfs $sublocallib/mindi 41 #chmod 755 $sublocallib/mindi/rootfs/sbin/* 42 #install -m 644 msg-txt dev.tgz $sublocallib/mindi 43 #install -m 644 deplist.txt udev.files proliant.files $conf 61 44 62 45 # Substitute variables for mindi 63 46 sed -i -e "s~^MINDI_PREFIX=XXX~MINDI_PREFIX=$sublocal~" -e "s~^MINDI_CONF=YYY~MINDI_CONF=$subconf~" -e "s~^MINDI_LIB=LLL~MINDI_LIB=$sublocallib~" $local/bin/mindi 64 sed -i -e "s~= "YYY"~= "$subconf"~" $local/bin/mindi-bkphw 65 install -m 755 parted2fdisk.pl $local/sbin 66 67 # Managing parted2fdisk 68 if [ "$ARCH" = "ia64" ] ; then 69 (cd $local/sbin && ln -sf parted2fdisk.pl parted2fdisk) 70 install -s -m 755 $local/sbin/parted2fdisk.pl $locallib/mindi/rootfs/sbin/parted2fdisk 71 # Try to avoid the need ot additional perl modules at the moment 72 perl -pi -e 's/use strict;//' $locallib/mindi/rootfs/sbin/parted2fdisk 73 else 74 # FHS requires fdisk under /sbin 75 (cd $local/sbin && ln -sf /sbin/fdisk parted2fdisk) 76 echo "Symlinking fdisk to parted2fdisk" 77 ( cd $locallib/mindi/rootfs/sbin && ln -sf fdisk parted2fdisk) 78 fi 47 #sed -i -e "s~= "YYY"~= "$subconf"~" $local/bin/mindi-bkphw 79 48 80 49 if [ "$PKGBUILDMINDI" != "true" ]; then 81 50 chown -R root:root $sublocallib/mindi $conf 82 chown root:root $local/sbin/parted2fdisk.pl83 if [ "$ARCH" = "ia64" ] ; then84 chown root:root $local/sbin/parted2fdisk85 fi86 51 fi 87 52 -
devel/mindi/sbin/mranalyze-lvm
r2149 r2538 141 141 } 142 142 143 my $ ret= mr_lvm_analyze($OUTPUT);143 my $lvmver = mr_lvm_analyze($OUTPUT); 144 144 145 if ($ ret== 0) {145 if ($lvmver == 0) { 146 146 pb_log(1,"No LVM handling") 147 147 } else { -
devel/mr/lib/MondoRescue/Base.pm
r2149 r2538 28 28 29 29 our @ISA = qw(Exporter); 30 our @EXPORT = qw(mr_ exit);30 our @EXPORT = qw(mr_init mr_exit); 31 31 32 32 =pod … … 44 44 =over 4 45 45 46 =item B<mr_init> 47 48 This function initialize MondoRescue, point to the right conf files, setup stuff 49 It takes 1 parameter, the message to print if needed 50 51 =cut 52 53 sub mr_exit { 54 55 my $msg = shift || ""; 56 57 if (defined $msg) { 58 pb_log($pbdebug,$msg); 59 } 60 61 pb_conf_init(); 62 } 46 63 =item B<mr_exit> 47 64
Note:
See TracChangeset
for help on using the changeset viewer.