From ed82396b927acd538c85151e80c3ebc744d50601 Mon Sep 17 00:00:00 2001 From: Francois Pons Date: Wed, 7 Aug 2002 15:09:11 +0000 Subject: added automatic update of lilo image and KDE & GNOME background. --- perl-install/install_steps.pm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) (limited to 'perl-install/install_steps.pm') diff --git a/perl-install/install_steps.pm b/perl-install/install_steps.pm index 47249b586..916fd53b9 100644 --- a/perl-install/install_steps.pm +++ b/perl-install/install_steps.pm @@ -306,6 +306,11 @@ sub beforeInstallPackages { log::l("setting excludedocs to $o->{excludedocs}"); substInFile { s/%_excludedocs.*//; $_ .= "%_excludedocs yes\n" if eof && $o->{excludedocs} } "$o->{prefix}/etc/rpm/macros"; + + #- add oem lilo theme and background if the files exists. + mkdir "$o->{prefix}$_" foreach qw(/boot /usr /usr/share /usr/share/mdk); + install_any::getAndSaveFile("Mandrake/base/oem-message-graphic", "$o->{prefix}/boot/oem-message-graphic"); + install_any::getAndSaveFile("Mandrake/base/oem-background.png", "$o->{prefix}/usr/share/mdk/oem-background.png"); } sub pkg_install { @@ -515,6 +520,31 @@ GridHeight=70 } } + #- update oem lilo image if it exists. + if (-s "/boot/oem-message-graphic") { + rename "$o->{prefix}/boot/message-graphic", "$o->{prefix}/boot/message-graphic.mdkgiorig"; + rename "$o->{prefix}/boot/oem-message-graphic", "$o->{prefix}/boot/message-graphic"; + } + + #- update background image if it exists for common environment. + if (-s -s "/usr/share/mdk/oem-background.png") { + #- KDE desktop background. + if (-e "$o->{prefix}/usr/share/config/kdesktoprc") { + update_gnomekderc("$o->{prefix}/usr/share/config/kdesktoprc", "Desktop0", + MultiWallpaperMode => "NoMulti", + Wallpaper => "/usr/share/mdk/oem-background.png", + WallpaperMode => "Scaled", + ); + } + #- GNOME desktop background. + if (-e "$o->{prefix}/etc/gnome/config/Background") { + update_gnomekderc("$o->{prefix}/etc/gnome/config/Background", "Default", + wallpaper => "/usr/share/mdk/oem-background.png", + wallpaperAlign => "3", + ); + } + } + if ($o->{blank} || $o->{updatemodules}) { my @l = detect_devices::floppies_dev(); -- cgit v1.2.1