diff options
-rwxr-xr-x | draklive-install | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/draklive-install b/draklive-install index 51c118e..11a86e9 100755 --- a/draklive-install +++ b/draklive-install @@ -131,6 +131,8 @@ open(my $OUTPUT, '-|', build_copy_command('/', $::prefix)); undef $update_progress; undef $wait; +sub clean_rpm_db { unlink(glob_(map { $_ . "/var/lib/rpm/__db.*" } "", $::prefix)) } + #- FIXME: maybe factorize with draklive, using draklive --clean-chroot ? #- remove unwanted files and packages my $live_user_desktop = chomp_(run_program::rooted_get_stdout($::prefix, "su - $live_user -c 'xdg-user-dir DESKTOP'")); @@ -138,7 +140,9 @@ unlink(map { $::prefix . $_ } '/.autofsck', '/etc/modprobe.d/mandriva-live', $live_user_desktop . '/draklive-copy-wizard.desktop', $live_user_desktop . '/draklive-install.desktop'); +clean_rpm_db(); system('chroot', $::prefix, 'rpm', '-e', 'draklive-install'); +clean_rpm_db(); #- enable first boot wizard at system boot output($::prefix . '/etc/sysconfig/firstboot', 'FIRSTBOOT=yes'); |