~ubuntu-branches/ubuntu/breezy/tipa/breezy

« back to all changes in this revision

Viewing changes to debian/gen-fonts-dir.pl

  • Committer: Bazaar Package Importer
  • Author(s): Rafael Laboissiere
  • Date: 2003-12-11 10:50:58 UTC
  • Revision ID: james.westby@ubuntu.com-20031211105058-85oz671r6s5b55c9
Tags: 2:1.2-1
* New upstream release.
* debian/Makefile.patch: Removed file, since my changes have been
  included upstream.
* debian/rules: Does not patch/depatch Makefile anymore.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/usr/bin/perl
 
2
 
 
3
($fontdir, $linkdir, $scale, $hints) = @ARGV;
 
4
 
 
5
open (HINTS, "< $hints");
 
6
undef $/;
 
7
@dir = ();
 
8
map {
 
9
  m{/([^/]+)\.pfb};
 
10
  $file = $1;
 
11
  if (/X-FontName = (.*)/) {
 
12
    $xfnt = $1;
 
13
    push @dir, "$file.pfb\t$xfnt";
 
14
    $xfnt =~ s/silipa-1/adobe-fontspecific/;
 
15
    push @dir, "$file.pfb\t$xfnt";
 
16
  }
 
17
  foreach $ext ("pfb", "afm") {
 
18
    system ("ln -fs $fontdir/$file.$ext $linkdir/$file.$ext\n");
 
19
  }
 
20
} split ("end\nbegin", <HINTS>);
 
21
close HINTS;
 
22
 
 
23
open (SCALE, ">$scale");
 
24
print SCALE scalar @dir, "\n", join ("\n", @dir);
 
25
close SCALE;