simplify ttmkfdir-3.0.9-encoding-dir.patch to drop X11R6/ check (#173705)
This commit is contained in:
parent
fe5c7ac2fd
commit
bac6483730
@ -5,35 +5,16 @@
|
||||
cerr << "This Program is (C) Joerg Pommnitz, 2000" << endl;
|
||||
cerr << "Usage: " << program << " [OPTION]" << endl;
|
||||
- cerr << "-e, --encoding\t\tname of the encoding directory file, default is \"/usr/X11R6/lib/X11/fonts/encodings/encodings.dir\"" << endl;
|
||||
+ cerr << "-e, --encoding\t\tname of the encoding directory file, default is \"/usr/X11R6/lib/X11/fonts/encodings/encodings.dir\" or \"/usr/share/X11/fonts/encodings/encodings.dir\"" << endl;
|
||||
+ cerr << "-e, --encoding\t\tname of the encoding directory file, default is \"/usr/share/X11/fonts/encodings/encodings.dir\"" << endl;
|
||||
cerr << "-o, --output\t\tname of the destination file, default is \"fonts.scale\"" << endl;
|
||||
cerr << "-d, --font-dir\t\tname of the TrueType font directory, default is \".\"" << endl;
|
||||
cerr << "-f, --default-foundry\tname of the default font foundry, default is \"misc\"" << endl;
|
||||
@@ -32,7 +32,26 @@
|
||||
@@ -32,7 +32,7 @@
|
||||
void
|
||||
ParseCommandline (int argc, char *argv[])
|
||||
{
|
||||
- cmdline::instance()->AddOption (new Commandline::Option ("encoding", 'e', "/usr/X11R6/lib/X11/fonts/encodings/encodings.dir"));
|
||||
+ FILE *tmp = fopen ("/usr/X11R6/lib/X11/fonts/encodings/encodings.dir", "r");
|
||||
+ if (tmp)
|
||||
+ {
|
||||
+ cmdline::instance()->AddOption (new Commandline::Option ("encoding", 'e', "/usr/X11R6/lib/X11/fonts/encodings/encodings.dir"));
|
||||
+ fclose (tmp);
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ tmp = fopen ("/usr/share/X11/fonts/encodings/encodings.dir", "r");
|
||||
+ if (tmp)
|
||||
+ {
|
||||
+ cmdline::instance()->AddOption (new Commandline::Option ("encoding", 'e', "/usr/share/X11/fonts/encodings/encodings.dir"));
|
||||
+ fclose (tmp);
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ cmdline::instance()->AddOption (new Commandline::Option ("encoding", 'e', "/usr/X11R6/lib/X11/fonts/encodings/encodings.dir"));
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ cmdline::instance()->AddOption (new Commandline::Option ("encoding", 'e', "/usr/share/X11/fonts/encodings/encodings.dir"));
|
||||
cmdline::instance()->AddOption (new Commandline::Option ("output", 'o', "fonts.scale"));
|
||||
cmdline::instance()->AddOption (new Commandline::Option ("font-dir", 'd', "."));
|
||||
cmdline::instance()->AddOption (new Commandline::Option ("default-foundry", 'f', "misc"));
|
||||
|
@ -1,7 +1,7 @@
|
||||
Summary: Utility to create fonts.scale files for truetype fonts
|
||||
Name: ttmkfdir
|
||||
Version: 3.0.9
|
||||
Release: 30%{?dist}
|
||||
Release: 31%{?dist}
|
||||
# This is a Red Hat maintained package which is specific to
|
||||
# our distribution. Thus the source is only available from
|
||||
# within this srpm.
|
||||
@ -62,6 +62,9 @@ rm -rf $RPM_BUILD_ROOT
|
||||
%{_bindir}/ttmkfdir
|
||||
|
||||
%changelog
|
||||
* Wed Jun 24 2009 Jens Petersen <petersen@redhat.com> - 3.0.9-31
|
||||
- simplify ttmkfdir-3.0.9-encoding-dir.patch to drop X11R6/ check (#173705)
|
||||
|
||||
* Tue Mar 03 2009 Caolán McNamara <caolanm@redhat.com> - 3.0.9-30
|
||||
- fix ttmkfdir-3.0.9-segfaults.patch to include stdio.h for added printf
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user