freebsd-ports/japanese/alias-fonts/pkg-deinstall
SADA Kenji f8d2c50bef Add new port alias-fonts, which obsoletes netscape-fonts.
As an improvement, it looks like same fonts irrespective of size.
It was renamed because it could be utilized with several Japanese apps, not only with Netscape.
You can trace the discussion at:
<http://home.jp.FreeBSD.org/cgi-bin/thread?mesid=%3c20020115163006%2e482281905%40taro%2ec%2eu%2dtokyo%2eac%2ejp%3e>

Submitted by:	KOMATSU Shinichiro <koma2@jiro.c.u-tokyo.ac.jp>
2002-04-09 09:05:22 +00:00

24 lines
524 B
Perl

#!/usr/bin/perl
# $FreeBSD$
$prefix = $ENV{'PKG_PREFIX'};
$dir = "$prefix/lib/X11/fonts/local";
$to = "$dir/fonts.alias";
$from = "$to.orig";
rename($to, $from) || die("Can't rename: $!");
open(IN, $from) || die("Can't open $from: $!");
open(OUT, ">$to") || die("Can't open $to: $!");
while (<IN>) {
chop;
if (/^\s*!/ || /^\s*$/) {
print OUT "$_\n";
}
else {
@line = split(/\s+/, $_);
@elm = split(/-+/, $line[0]);
if ($elm[1] ne 'alias') {
print OUT "$_\n";
}
}
}
#system("$prefix/bin/xset fp rehash");