Accepting request 264391 from M17N
- updated to 20141207 added --info option (will be required by yast fonts) OBS-URL: https://build.opensuse.org/request/show/264391 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/fonts-config?expand=0&rev=44
This commit is contained in:
commit
c0cfc4fc6e
63
fonts-config
63
fonts-config
@ -154,6 +154,10 @@ Display version and exit.
|
||||
|
||||
Display a short help message and exit.
|
||||
|
||||
=item B<-i>, B<--info>
|
||||
|
||||
Lists important involved input and output files to fonts-config script.
|
||||
|
||||
=back
|
||||
|
||||
=head1 DESCRIPTION
|
||||
@ -316,7 +320,7 @@ use Env;
|
||||
use strict;
|
||||
|
||||
my $script_start_time = time();
|
||||
my $version = 20140604;
|
||||
my $version = 20141207;
|
||||
|
||||
#
|
||||
# OPTIONS
|
||||
@ -343,6 +347,7 @@ my $OPT_TTCAP = 0;
|
||||
my $OPT_JAVA = 1;
|
||||
my $OPT_VERSION = 0;
|
||||
my $OPT_HELP = 0;
|
||||
my $OPT_INFO = 0;
|
||||
|
||||
my $VERBOSITY_QUIET = 0;
|
||||
my $VERBOSITY_VERBOSE = 1;
|
||||
@ -370,9 +375,22 @@ my %sysconfig_options = (
|
||||
"GENERATE_JAVA_FONT_SETUP" , "OPT_JAVA",
|
||||
);
|
||||
|
||||
my %in_files = (
|
||||
"sysconfig file", "/etc/sysconfig/fonts-config",
|
||||
"rendering config template", "/usr/share/fonts-config/10-rendering-options.conf.template",
|
||||
"metric compatibility config", "/usr/share/fontconfig/conf.avail/30-metric-aliases.conf",
|
||||
"metric compatibility bw config", "/usr/share/fonts-config/conf.avail/31-metric-aliases-bw.conf",
|
||||
"java fontconfig properties template", "/usr/share/fonts-config/fontconfig.SuSE.properties.template",
|
||||
);
|
||||
my %out_files = (
|
||||
"rendering config", "/etc/fonts/conf.d/10-rendering-options.conf",
|
||||
"local family list", "/etc/fonts/conf.d/58-family-prefer-local.conf",
|
||||
"metric compatibility symlink", "/etc/fonts/conf.d/30-metric-aliases.conf",
|
||||
"metric compatibility bw symlink", "/etc/fonts/conf.d/31-metric-aliases-bw.conf",
|
||||
"java fontconfig properties", "/usr/lib*/jvm/jre/lib/fontconfig.SuSE.properties",
|
||||
);
|
||||
|
||||
|
||||
get_option_defaults_from_sysconfig("/etc/sysconfig/fonts-config");
|
||||
get_option_defaults_from_sysconfig($in_files{"sysconfig file"});
|
||||
|
||||
# process command line options
|
||||
my %opt;
|
||||
@ -398,6 +416,7 @@ unless (GetOptions(\%opt,
|
||||
'java!', \$OPT_JAVA,
|
||||
'version', \$OPT_VERSION,
|
||||
'help|h', \$OPT_HELP,
|
||||
'info|i', \$OPT_INFO,
|
||||
)) {
|
||||
&usage ();
|
||||
exit 1;
|
||||
@ -421,6 +440,24 @@ if ($OPT_HELP) {
|
||||
exit 0;
|
||||
}
|
||||
|
||||
#
|
||||
# INFO
|
||||
#
|
||||
|
||||
if ($OPT_INFO) {
|
||||
# this is read by yast-fonts, so may be that
|
||||
# change should be reflected in this yast module
|
||||
print "Input Files\n";
|
||||
for my $f (keys %in_files) {
|
||||
print " $f: $in_files{$f}\n"
|
||||
}
|
||||
print "Output Files\n";
|
||||
for my $f (keys %out_files) {
|
||||
print " $f: $out_files{$f}\n"
|
||||
}
|
||||
exit 0;
|
||||
}
|
||||
|
||||
#
|
||||
# VERBOSITY
|
||||
#
|
||||
@ -442,7 +479,7 @@ elsif ($OPT_VERBOSE) {
|
||||
no strict "vars";
|
||||
no warnings;
|
||||
if ($VERBOSITY >= $VERBOSITY_DEBUG) {
|
||||
print "--- sysconfig options (read from $sysconfig_file):\n";
|
||||
print "--- sysconfig options (read from $in_files{'sysconfig file'}):\n";
|
||||
for my $i (keys %sysconfig_options) {
|
||||
if (defined eval ("\$$i")) {
|
||||
printf "$i=%s\n", eval("\$$i");
|
||||
@ -1037,8 +1074,8 @@ sub create_symbolic_links {
|
||||
#
|
||||
|
||||
sub rendering_options {
|
||||
my $suse_rendering_file = "/etc/fonts/conf.d/10-rendering-options.conf";
|
||||
my $suse_rendering_template_file = "/usr/share/fonts-config/10-rendering-options.conf.template";
|
||||
my $suse_rendering_file = $out_files{"rendering config"};
|
||||
my $suse_rendering_template_file = $in_files{"rendering config template"};
|
||||
my $suse_rendering = "";
|
||||
my $suse_rendering_template = "";
|
||||
|
||||
@ -1230,11 +1267,11 @@ sub family_preference_list {
|
||||
}
|
||||
|
||||
sub family_preference_config {
|
||||
my $suse_pref_file = "/etc/fonts/conf.d/58-family-prefer-local.conf";
|
||||
my $metric_file = "/usr/share/fontconfig/conf.avail/30-metric-aliases.conf";
|
||||
my $bw_metric_file = "/usr/share/fonts-config/conf.avail/31-metric-aliases-bw.conf";
|
||||
my $metric_symlink = "/etc/fonts/conf.d/30-metric-aliases.conf";
|
||||
my $bw_metric_symlink = "/etc/fonts/conf.d/31-metric-aliases-bw.conf";
|
||||
my $suse_pref_file = $out_files{"local family list"};
|
||||
my $metric_file = $in_files{"metric compatibility config"};
|
||||
my $bw_metric_file = $in_files{"metric compatibility bw config"};
|
||||
my $metric_symlink = $out_files{"metric compatibility symlink"};
|
||||
my $bw_metric_symlink = $out_files{"metric compatibility bw symlink"};
|
||||
my $suse_pref = "";
|
||||
my $edit_options;
|
||||
|
||||
@ -1362,8 +1399,8 @@ sub run_fp_rehash {
|
||||
#
|
||||
|
||||
sub generate_java_font_setup {
|
||||
my @fontconfig_SuSE_properties_globs = "/usr/lib*/jvm/jre/lib/fontconfig.SuSE.properties";
|
||||
my $fontconfig_SuSE_properties_template_file = "/usr/share/fonts-config/fontconfig.SuSE.properties.template";
|
||||
my @fontconfig_SuSE_properties_globs = $out_files{"java fontconfig properties"};
|
||||
my $fontconfig_SuSE_properties_template_file = $in_files{"java fontconfig properties template"};
|
||||
my $fontconfig_SuSE_properties_template = "";
|
||||
my @sans_japanese_priority = ("MS Gothic",
|
||||
"HGGothicB",
|
||||
|
@ -1,3 +1,9 @@
|
||||
-------------------------------------------------------------------
|
||||
Sun Dec 7 21:42:17 UTC 2014 - pgajdos@suse.com
|
||||
|
||||
- updated to 20141207
|
||||
added --info option (will be required by yast fonts)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Sep 22 13:19:56 UTC 2014 - pgajdos@suse.com
|
||||
|
||||
|
@ -19,7 +19,7 @@
|
||||
%define infinality_srcver 1-20130104_1
|
||||
%define infinality_name fontconfig-infinality
|
||||
Name: fonts-config
|
||||
Version: 20140604
|
||||
Version: 20141207
|
||||
Release: 0
|
||||
Summary: Configures Fonts for X Windows and other applications
|
||||
License: GPL-2.0+ and MIT
|
||||
|
Loading…
x
Reference in New Issue
Block a user