diff options
author | Francois Pons <fpons@mandriva.com> | 2000-09-28 16:33:49 +0000 |
---|---|---|
committer | Francois Pons <fpons@mandriva.com> | 2000-09-28 16:33:49 +0000 |
commit | a3e2c7be4443cb41d435ea38cd7f3e253709afcc (patch) | |
tree | d19d2b513c6f268cbe4c912068b85a3b2fc941d0 /perl-install | |
parent | f9128b9427f10815fb59db2eb65ee29a8d80b6d8 (diff) | |
download | drakx-a3e2c7be4443cb41d435ea38cd7f3e253709afcc.tar drakx-a3e2c7be4443cb41d435ea38cd7f3e253709afcc.tar.gz drakx-a3e2c7be4443cb41d435ea38cd7f3e253709afcc.tar.bz2 drakx-a3e2c7be4443cb41d435ea38cd7f3e253709afcc.tar.xz drakx-a3e2c7be4443cb41d435ea38cd7f3e253709afcc.zip |
*** empty log message ***
Diffstat (limited to 'perl-install')
-rw-r--r-- | perl-install/ChangeLog | 9 | ||||
-rw-r--r-- | perl-install/Makefile.config | 2 | ||||
-rw-r--r-- | perl-install/install_any.pm | 2 | ||||
-rwxr-xr-x | perl-install/live_install | 46 | ||||
-rwxr-xr-x | perl-install/live_install2 | 15 | ||||
-rw-r--r-- | perl-install/printerdrake.pm | 6 | ||||
-rwxr-xr-x | perl-install/standalone/livedrake | 18 |
7 files changed, 37 insertions, 61 deletions
diff --git a/perl-install/ChangeLog b/perl-install/ChangeLog index 6ae14facd..78d819140 100644 --- a/perl-install/ChangeLog +++ b/perl-install/ChangeLog @@ -11,9 +11,16 @@ 2000-09-28 François Pons <fpons@mandrakesoft.com> + * Makefile.config: added livedrake for drakxtools. * diskdrake.pm: use corrected partition size when resizing a dos partition (like the others). - * printerdrake.pm: protect set_help() usage by if $::isInstall. + * install_any.pm: no more pnm2ppa packages and others in package + to copy when changing CD. + * live_install: exec live_install2 instead. + * live_install2: contains post live upgrade stuff now. + * printerdrake.pm: protect set_help() usage by if $::isInstall, + removed reference to package pnm2ppa and others. + * standalone/livedrake: initial release for drakxtools. 2000-09-28 DrakX <install@linux-mandrake.com> diff --git a/perl-install/Makefile.config b/perl-install/Makefile.config index 76bcffe3e..a24f67bc8 100644 --- a/perl-install/Makefile.config +++ b/perl-install/Makefile.config @@ -5,7 +5,7 @@ VERSION = 2.2.10-BOOT SUDO = sudo SO_FILES = c/blib/arch/auto/c/c.so PMS = *.pm Newt/*.pm c/stuff.pm resize_fat/*.pm pci_probing/*.pm sbus_probing/*.pm commands install2 g_auto_install live_install live_install2 -STANDALONEPMS= diskdrake XFdrake mousedrake lspcidrake printerdrake keyboarddrake netdrake draknet drakxconf drakxservices draksec drakboot adduserdrake rpmdrake drakgw +STANDALONEPMS= diskdrake XFdrake mousedrake lspcidrake printerdrake keyboarddrake netdrake draknet drakxconf drakxservices draksec drakboot adduserdrake rpmdrake drakgw livedrake PMS += $(STANDALONEPMS:%=standalone/%) REP4PMS = /usr/bin/perl-install ROOTDEST = /export diff --git a/perl-install/install_any.pm b/perl-install/install_any.pm index 3331c9e6e..982ba85a4 100644 --- a/perl-install/install_any.pm +++ b/perl-install/install_any.pm @@ -34,7 +34,7 @@ XFree86-P9000 XFree86-S3 XFree86-S3V XFree86-SVGA XFree86-W32 XFree86-I128 XFree86-Sun XFree86-SunMono XFree86-Sun24 XFree86-3DLabs XFree86-FBDev XFree86-server XFree86 XFree86-glide-module Device3Dfx Glide_V3-DRI Glide_V5 Mesa dhcpcd pump dhcpxd dhcp-client isdn4net isdn4k-utils dev pptp-adsl-fr rp-pppoe ppp ypbind -rhs-printfilters lpr cups cups-drivers pnm2ppa Lexmark-1100-printer-driver__lm1100 samba ncpfs +rhs-printfilters lpr cups cups-drivers samba ncpfs ); #- package that have to be copied only if all their requires are satisfied. @needToCopyIfRequiresSatisfied = qw( diff --git a/perl-install/live_install b/perl-install/live_install index 113cf5660..a98583690 100755 --- a/perl-install/live_install +++ b/perl-install/live_install @@ -49,47 +49,9 @@ if [ -x "/tmp/drakx/mdkinst/usr/bin/perl-install/live_install2" ]; then xset fp rehash fi - # start DrakX - ../../../lib/ld-linux.so.2 ../perl ./live_install2 - - # restore all fonts dir from 7.2 in case something gets wrong. - for i in misc PEX Speedo Type1 mdk 75dpi 100dpi cyrillic - do - if [ -d /usr/X11R6/lib/X11/fonts/$i ]; then - if [ ! -e /usr/X11R6/lib/X11/fonts/$i/fonts.dir ]; then - cd /usr/X11R6/lib/X11/fonts/$i - mkfontdir - if [ -n "$DISPLAY" ]; then - xset fp rehash - fi - cd - - fi - fi - done - -# for i in MonitorsDB CardsNames Cards+ -# do -# if [ -e /tmp/drakx/mdkinst/$i ]; then -# rm -f /usr/X11R6/lib/X11/$i -# mv /tmp/drakx/mdkinst/$i /usr/X11R6/lib/X11/$i -# fi -# done -# -# if [ -x /tmp/drakx/mdkinst/packdrake ]; then -# rm -f /usr/bin/packdrake -# mv /tmp/drakx/mdkinst/packdrake /usr/bin/packdrake -# fi -# -# if [ -x /tmp/drakx/mdkinst/libperl.so ]; then -# rm -f $perlcoredir/libperl.so -# 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" - exit 2 + # start DrakX, do not keep shell script in background else the CD is locked by it!!! + exec ../../../lib/ld-linux.so.2 ../perl ./live_install2 fi -#/bin/rm -rf /tmp/drakx -#/bin/rm -rf /tmp/rhimage - -sync +echo >&2 "unable to get a working live system to start, check your working directory" +exit 2 diff --git a/perl-install/live_install2 b/perl-install/live_install2 index 0773636ea..e2a07f4c5 100755 --- a/perl-install/live_install2 +++ b/perl-install/live_install2 @@ -9,4 +9,17 @@ $ENV{LD_LIBRARY_PATH} = "$dir/lib:$dir/usr/lib"; $ENV{PATH} = join(":", map { "$dir/$_" } split ":", "/usr/bin:/bin:/sbin:/usr/sbin:/usr/X11R6/bin") . ":$ENV{PATH}"; $ENV{SHARE_PATH} = "$dir/usr/share"; -exec "../../../lib/ld-linux.so.2", "../perl", "./install2", "--live", @ARGV or die; +system "../../../lib/ld-linux.so.2", "../perl", "./install2", "--live", @ARGV; + +foreach (qw(misc PEX Speedo Type1 mdk 75dpi 100dpi cyrillic)) { + -d "/usr/X11R6/lib/X11/fonts/$_" or next; + -e "/usr/X11R6/lib/X11/fonts/$_/fonts.dir" and next; + chdir "/usr/X11R6/lib/X11/fonts/$_"; + system "mkfontdir"; + $ENV{DISPLAY} and system "xset", "fp", "rehash"; +} + +system "/bin/rm", "-rf", "/tmp/drakx"; +system "/bin/rm", "-rf", "/tmp/rhimage"; + +exec "/bin/sync"; diff --git a/perl-install/printerdrake.pm b/perl-install/printerdrake.pm index 5d91424bd..151c5dd0e 100644 --- a/perl-install/printerdrake.pm +++ b/perl-install/printerdrake.pm @@ -190,8 +190,8 @@ sub setup_gsdriver_cups($$$;$) { $printer->{cupsPPD} = $printer::descr_to_ppd{$printer->{cupsDescr}}; #- install additional filter according to PPD files. - $printer->{cupsPPD} =~ /-pnm2ppa\.ppd/ and &$install('pnm2ppa'); - $printer->{cupsPPD} =~ /-lm1100\.ppd/ and &$install('Lexmark-1100-printer-driver__lm1100'); + #-$printer->{cupsPPD} =~ /-pnm2ppa\.ppd/ and &$install('pnm2ppa'); + #-$printer->{cupsPPD} =~ /-lm1100\.ppd/ and &$install('Lexmark-1100-printer-driver__lm1100'); $printer->{complete} = 1; printer::copy_printer_params($printer, $printer->{configured}{$printer->{QUEUE}} ||= {}); @@ -249,7 +249,7 @@ sub setup_gsdriver_lpr($$$;$) { my %db_entry = %{$printer::thedb{$printer->{DBENTRY}}}; #- specific printer drivers to install. - &$install('pnm2ppa') if $db_entry{GSDRIVER} eq 'ppa'; + #-&$install('pnm2ppa') if $db_entry{GSDRIVER} eq 'ppa'; my @list_res = @{$db_entry{RESOLUTION} || []}; my @res = map { "$_->{XDPI}x$_->{YDPI}" } @list_res; diff --git a/perl-install/standalone/livedrake b/perl-install/standalone/livedrake index b9c1e9471..f93cfefbb 100755 --- a/perl-install/standalone/livedrake +++ b/perl-install/standalone/livedrake @@ -2,9 +2,9 @@ use lib qw(/usr/lib/libDrakX); -use common qw(:common :system); +use common qw(:common :system :file); use interactive; -use mouse; +use run_program; use c; local $_ = join '', @ARGV; @@ -23,7 +23,7 @@ while (! -x "$cd_mntpoint/Mandrake/mdkinst/usr/bin/perl-install/live_install") { $in->ask_okcancel(_("Change Cd-Rom"), _("Please insert the Installation Cd-Rom in your drive and press Ok when done. If you don't have it, press Cancel to avoid live upgrade."), 1) or $in->exit(0); - eval { fs::mount("/mnt/cdrom") }; + run_program::run("mount", "/mnt/cdrom"); } if (-x "$cd_mntpoint/Mandrake/mdkinst/usr/bin/perl-install/live_install") { @@ -34,18 +34,12 @@ if (-x "$cd_mntpoint/Mandrake/mdkinst/usr/bin/perl-install/live_install") { $in->ask_warn('', _("Unable to start live upgrade !!!\n")); $in->exit(1); -sub unlockCdrom { - my ($cdrom) = @_; - $cdrom or cat_("/proc/mounts") =~ m|(/dev/\S+)\s+/mnt/cdrom\s| and $cdrom = $1; - $cdrom or cat_("/etc/fstab") =~ m|(/dev/\S+)\s+/mnt/cdrom\s| and $cdrom = $1; - eval { $cdrom and ioctl detect_devices::tryOpen($1), c::CDROM_LOCKDOOR(), 0 }; -} - sub ejectCdrom { my ($cdrom) = @_; $cdrom or cat_("/proc/mounts") =~ m|(/dev/\S+)\s+/mnt/cdrom\s| and $cdrom = $1; + $cdrom or cat_("/etc/fstab") =~ m|(/dev/\S+)\s+/mnt/cdrom\s| and $cdrom = $1; my $f = eval { $cdrom && detect_devices::tryOpen($cdrom) } or return; - getFile("XXX"); #- close still opened filehandle - eval { fs::umount("/mnt/cdrom") }; + run_program::run("umount", "/mnt/cdrom"); + ioctl $f, c::CDROM_LOCKDOOR(), 0; ioctl $f, c::CDROMEJECT(), 1; } |