summaryrefslogtreecommitdiffstats
path: root/perl-install/standalone
diff options
context:
space:
mode:
Diffstat (limited to 'perl-install/standalone')
-rwxr-xr-xperl-install/standalone/drakfont29
1 files changed, 21 insertions, 8 deletions
diff --git a/perl-install/standalone/drakfont b/perl-install/standalone/drakfont
index 441214aa2..d816e9014 100755
--- a/perl-install/standalone/drakfont
+++ b/perl-install/standalone/drakfont
@@ -296,14 +296,26 @@ sub put_font_dir {
}
-# todo : finir supperssion fontes Types!
sub remove_gs_fonts {
- if (listlength all("$drakfont_dir/remove ")) {
- system (" cd $drakfont_dir/remove && $type1inst ");
- my @font_out = cat_("$drakfont_dir/remove/Fontmap");
- my @font_out = cat_("$drakfont_dir/remove/Fontmap");
+ my @Fontmap_new;
+
+ if (all("$drakfont_dir/remove")) {
+ system (" cd $drakfont_dir/remove && $type1inst && touch tttttttttt");
+ my @Fontmap_out = cat_("$drakfont_dir/remove/Fontmap");
+ my $FontmapGS = `rpm -ql ghostscript | grep Fontmap.GS`;
+ chomp ($FontmapGS);
+ my @FontmapGS_list = cat_($FontmapGS);
+ foreach my $font_gs (@FontmapGS_list) {
+ my @tmp_list = split (' ',$font_gs);
+ grep ( $_ =~ /$tmp_list[0]/ , @Fontmap_out) or push @Fontmap_new, $font_gs;
+ }
+ print $_ foreach @Fontmap_new;
+ output($FontmapGS.".tmp2", @Fontmap_new );
+ }
}
+
+
sub remove_fonts {
my @list_dir;
my @toto;
@@ -311,7 +323,7 @@ sub remove_fonts {
foreach my $i (@font_list) {
$_ = $i;
if ( /.pfb$/ || /.pfm$/ || /.pfa$/ ) {
- system ("mv $_ $drakfont_dir/remove ");
+ system ("cp $_ $drakfont_dir/remove ");
}
else {
rm_rf($i);
@@ -330,12 +342,13 @@ sub remove_fonts {
# # do type1inst in this path
system("cd $i && type1inst") or print "PERL::system command failed during cd or type1inst\n";
}
- }
- -e "/usr/share/ghostscript" and rm_rf("$drakfont_dir/remove");
}
+ system ("/etc/rc.d/init.d/xfs restart");
+ -e "/usr/share/ghostscript" and rm_rf("$drakfont_dir/remove");
}
+
$xlsfonts || $windows || @install || @uninstall ? backend_mod() : interactive_mode();
sub backend_mod {