summaryrefslogtreecommitdiffstats
path: root/perl-install/live_install
diff options
context:
space:
mode:
authorFrancois Pons <fpons@mandriva.com>2000-09-06 14:21:26 +0000
committerFrancois Pons <fpons@mandriva.com>2000-09-06 14:21:26 +0000
commitcc85e855ad2d11bddbabc9e0a4d4e41df5ff6cc7 (patch)
treefdc3ea1a0c8929885df80852b7225f3c348cc3cf /perl-install/live_install
parentfe108560318dbdae544d30e6850177288c814066 (diff)
downloaddrakx-cc85e855ad2d11bddbabc9e0a4d4e41df5ff6cc7.tar
drakx-cc85e855ad2d11bddbabc9e0a4d4e41df5ff6cc7.tar.gz
drakx-cc85e855ad2d11bddbabc9e0a4d4e41df5ff6cc7.tar.bz2
drakx-cc85e855ad2d11bddbabc9e0a4d4e41df5ff6cc7.tar.xz
drakx-cc85e855ad2d11bddbabc9e0a4d4e41df5ff6cc7.zip
*** empty log message ***
Diffstat (limited to 'perl-install/live_install')
-rwxr-xr-xperl-install/live_install66
1 files changed, 38 insertions, 28 deletions
diff --git a/perl-install/live_install b/perl-install/live_install
index 4f519f0fc..a9440db3e 100755
--- a/perl-install/live_install
+++ b/perl-install/live_install
@@ -1,28 +1,38 @@
-#!../perl
-
-my $dir = `pwd`;
-chomp $dir;
-$dir .= "/../../..";
-
-#- update /tmp/rhimage which points to top dir of Mandrake CD.
-system "/bin/rm", "-rf", "/tmp/rhimage";
-mkdir "/tmp/rhimage", 0700 or die "cannot create directory /tmp/rhimage";
-system "/bin/rm", "-rf", "/tmp/drakx";
-mkdir "/tmp/drakx", 0700 or die "cannot create directory /tmp/drakx\n";
-
-#- copy whole set of mdkinst tree and symlink to the CD.
-foreach (qw(Mandrake RPMS misc boot images)) {
- symlink "$dir/../../$_", "/tmp/rhimage/$_";
-}
-system "/bin/cp", "-a", "$dir/../../Mandrake/mdkinst", "/tmp/drakx";
-
-#- start the true live_install.
-if (-x "/tmp/drakx/mdkinst/usr/bin/perl-install/live_install2") {
- chdir "/tmp/drakx/mdkinst/usr/bin/perl-install2";
- system "/tmp/drakx/mdkinst/usr/bin/perl-install/live_install2";
-} else {
- print STDERR "unable to get a working live system to start, check your working directory";
-}
-
-system "/bin/rm", "-rf", "/tmp/drakx";
-system "/bin/rm", "-rf", "/tmp/rhimage";
+#!/bin/sh
+
+dir=`pwd`/../../..
+
+/bin/rm -rf /tmp/rhimage
+mkdir -m 0700 /tmp/rhimage || exit 1
+/bin/rm -rf /tmp/drakx
+mkdir -m 0700 /tmp/drakx || exit 2
+
+for i in Mandrake RPMS misc boot images
+do
+ ln -sf "$dir/../../$i" "/tmp/rhimage/$i"
+done
+
+/bin/cp -a "$dir/../../Mandrake/mdkinst" "/tmp/drakx"
+
+if [ -x "/tmp/drakx/mdkinst/usr/bin/perl-install/live_install2" ]; then
+ $perlcoredir=/usr/lib/perl5/5.6.0/i386-linux/CORE
+ cd /tmp/drakx/mdkinst/usr/bin/perl-install
+ if [ -x $perlcoredir/libperl.so ]; then
+ mv $perlcoredir/libperl.so /tmp/drakx/mdkinst
+ else
+ mkdir -p $perlcoredir
+ ln -sf /tmp/drakx/mdkinst/$perlcoredir/libperl.so $perlcoredir/libperl.so
+ fi
+
+ ../../../lib/ld-linux.so.2 ../perl ./live_install2
+
+ rm -f $perlcoredir/libperl.so
+ if [ -x /tmp/drakx/mdkinst ]; then
+ mv /tmp/drakx/mdkinst/libperl.so $perlcoredir/libperl.so
+ fi
+else
+ echo >&2 "unable to get a working live system to start, check your working directory"
+fi
+
+#/bin/rm -rf /tmp/drakx
+#/bin/rm -rf /tmp/rhimage