Sync from SUSE:ALP:Source:Standard:1.0 fontpackages revision 0217bec954f40d6acb52692d0a9ac437
This commit is contained in:
commit
4249482bd1
23
.gitattributes
vendored
Normal file
23
.gitattributes
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
## Default LFS
|
||||
*.7z filter=lfs diff=lfs merge=lfs -text
|
||||
*.bsp filter=lfs diff=lfs merge=lfs -text
|
||||
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.gem filter=lfs diff=lfs merge=lfs -text
|
||||
*.gz filter=lfs diff=lfs merge=lfs -text
|
||||
*.jar filter=lfs diff=lfs merge=lfs -text
|
||||
*.lz filter=lfs diff=lfs merge=lfs -text
|
||||
*.lzma filter=lfs diff=lfs merge=lfs -text
|
||||
*.obscpio filter=lfs diff=lfs merge=lfs -text
|
||||
*.oxt filter=lfs diff=lfs merge=lfs -text
|
||||
*.pdf filter=lfs diff=lfs merge=lfs -text
|
||||
*.png filter=lfs diff=lfs merge=lfs -text
|
||||
*.rpm filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.tgz filter=lfs diff=lfs merge=lfs -text
|
||||
*.ttf filter=lfs diff=lfs merge=lfs -text
|
||||
*.txz filter=lfs diff=lfs merge=lfs -text
|
||||
*.whl filter=lfs diff=lfs merge=lfs -text
|
||||
*.xz filter=lfs diff=lfs merge=lfs -text
|
||||
*.zip filter=lfs diff=lfs merge=lfs -text
|
||||
*.zst filter=lfs diff=lfs merge=lfs -text
|
30
COPYING
Normal file
30
COPYING
Normal file
@ -0,0 +1,30 @@
|
||||
Copyright (c) 2000-2011, Novell, Inc.
|
||||
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright notice,
|
||||
this list of conditions and the following disclaimer.
|
||||
|
||||
* Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the distribution.
|
||||
|
||||
* Neither the name of the Novell nor the names of its contributors may
|
||||
be used to endorse or promote products derived from this software
|
||||
without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
|
||||
IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
|
||||
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
|
||||
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER
|
||||
OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
||||
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
||||
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
||||
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
123
fontpackages.changes
Normal file
123
fontpackages.changes
Normal file
@ -0,0 +1,123 @@
|
||||
-------------------------------------------------------------------
|
||||
Fri Jun 11 11:49:27 UTC 2021 - Dominique Leuenberger <dimstar@opensuse.org>
|
||||
|
||||
- Move /macros.fonts-config from /etc/rpm to %{_rpmmacrodir}
|
||||
(boo#1185657).
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Nov 21 15:14:15 CET 2017 - kukuk@suse.de
|
||||
|
||||
- /var/adm/update-scripts is deprecated and will be removed at
|
||||
some point in the future, since %posttrans support in libzypp
|
||||
was fixed with SLE12. Remove the workaround, only use the RPM
|
||||
posttrans to simplify the code and testing.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Mar 14 14:30:28 UTC 2016 - pgajdos@suse.com
|
||||
|
||||
- fix previous commit
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Mar 7 15:36:53 UTC 2016 - olaf@aepfle.de
|
||||
|
||||
- Update reconfigure_fonts_post to use shell variables
|
||||
to reduce build-compare noise in font packages
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Oct 21 09:27:48 UTC 2015 - dmueller@suse.com
|
||||
|
||||
- remove references to /var/run (bsc#951354)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Feb 5 11:16:17 UTC 2015 - olaf@aepfle.de
|
||||
|
||||
- Revert last pathname change because libzypp expects a fixed
|
||||
filename pattern. release changes have to caught in build-compare
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Feb 3 08:24:45 UTC 2015 - olaf@aepfle.de
|
||||
|
||||
- Move version-release to reduce build-compare noise
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Feb 27 15:48:37 UTC 2014 - pgajdos@suse.com
|
||||
|
||||
- require coreutils for scriptlets of fontpackages [bnc#865853]
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jan 22 14:18:02 UTC 2014 - pgajdos@suse.com
|
||||
|
||||
- fonts-config is --quiet in every call
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Oct 15 11:16:42 UTC 2013 - pgajdos@suse.com
|
||||
|
||||
- fixed minor typo in %reconfigure_fonts_post macro [bnc#845955]
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Oct 14 06:05:19 UTC 2013 - pgajdos@suse.com
|
||||
|
||||
- minor fix in %reconfigure_fonts_post macro (really check for
|
||||
cjk *-config before run them)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Sep 30 08:44:46 UTC 2013 - pgajdos@suse.com
|
||||
|
||||
- run fonts-config only once when installing or upgrading more
|
||||
fonts in one transaction
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jan 2 09:25:45 UTC 2013 - pgajdos@suse.com
|
||||
|
||||
- %reconfigure_fonts_scriptlets macro does not contain (now empty)
|
||||
%posttrans from now on until
|
||||
https://bugzilla.novell.com/show_bug.cgi?id=773575
|
||||
is not resolved
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Oct 8 12:39:33 UTC 2012 - pgajdos@suse.com
|
||||
|
||||
- introduced new rpm macro: %files_fontsconf_availdir
|
||||
to be included in %files section of package which ships own
|
||||
fontconfig files; expands in
|
||||
/usr/share/%{name}
|
||||
/usr/share/%{name}/conf.avail
|
||||
- introduced new rpm macro: %files_fontsconf_file
|
||||
to be included in %files section of package which ships own
|
||||
fontconfig file;
|
||||
|
||||
%files_fontsconf_file -l name.conf
|
||||
|
||||
expands in
|
||||
/usr/share/%{name}/conf.avail/name.conf
|
||||
%config /etc/fonts/conf.d/name.conf
|
||||
|
||||
when -l switch isn't supplied, only
|
||||
/usr/share/%{name}/conf.avail/name.conf
|
||||
is packaged
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Oct 2 15:34:14 UTC 2012 - pgajdos@suse.com
|
||||
|
||||
- introduced new rpm macro: %install_fontsconf
|
||||
for given file (path/to/01-font.conf), it
|
||||
1. creates %{_fontsconfavaildir}
|
||||
2. copies path/to/01-font.conf to %{_fontsconfavaildir}
|
||||
uses %link_avail_to_system_fontsconf to
|
||||
3. create %{_fontsconfddir}
|
||||
4. link %{_fontsavaildir}/01-fonts.conf %{_fontsconfddir}
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Oct 2 11:33:46 UTC 2012 - pgajdos@suse.com
|
||||
|
||||
- modified %_fontsconfavaildir to from
|
||||
/etc/fonts/conf.avail to /usr/share/%{name}/conf.avail as
|
||||
fontconfig 2.10 ship its avail conf in /usr/share/fontconfig/conf.avail
|
||||
- added %link_avail_to_system_fontsconf, which creates symlink pointing
|
||||
from /etc/fonts/conf.d to ../../../usr/share/%{name}/conf.avail
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Jul 3 13:02:24 UTC 2012 - pgajdos@suse.com
|
||||
|
||||
- package created, added rpm-macros.fonts-config
|
||||
|
52
fontpackages.spec
Normal file
52
fontpackages.spec
Normal file
@ -0,0 +1,52 @@
|
||||
#
|
||||
# spec file for package fontpackages
|
||||
#
|
||||
# Copyright (c) 2021 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
|
||||
Name: fontpackages
|
||||
Version: 0.2
|
||||
Release: 0
|
||||
Summary: Commons for Font Packages
|
||||
License: BSD-3-Clause
|
||||
Group: System/Base
|
||||
Source0: rpm-macros.fonts-config
|
||||
Source100: COPYING
|
||||
BuildArch: noarch
|
||||
|
||||
%description
|
||||
Commons for font packages.
|
||||
|
||||
%package devel
|
||||
Summary: Development Commons for Font Packages
|
||||
Group: Development/Tools/Building
|
||||
|
||||
%description devel
|
||||
Development commons for font packages.
|
||||
|
||||
%prep
|
||||
|
||||
%build
|
||||
cp %{SOURCE100} .
|
||||
|
||||
%install
|
||||
mkdir -p %{buildroot}%{_rpmmacrodir}
|
||||
cp -a %{SOURCE0} %{buildroot}%{_rpmmacrodir}/macros.fonts-config
|
||||
|
||||
%files devel
|
||||
%license COPYING
|
||||
%{_rpmmacrodir}/macros.fonts-config
|
||||
|
||||
%changelog
|
159
rpm-macros.fonts-config
Normal file
159
rpm-macros.fonts-config
Normal file
@ -0,0 +1,159 @@
|
||||
# directories
|
||||
%_fontsdir %{_usr}/share/fonts
|
||||
%_ttfontsdir %{_fontsdir}/truetype
|
||||
%_miscfontsdir %{_fontsdir}/misc
|
||||
%_fontsconfdir %{_sysconfdir}/fonts
|
||||
%_fontsconfddir %{_fontsconfdir}/conf.d
|
||||
%_fontsconfavaildir %{_datadir}/%{name}/conf.avail
|
||||
# private
|
||||
%__fontsconfigrunflag %{_rundir}/fontpackages/reconfigure-fonts
|
||||
|
||||
# macro: link_avail_to_system_fontsconf name
|
||||
# (takes exactly one argument, name of configuration file)
|
||||
# creates symlink pointing from /etc/fonts/conf.d/name to
|
||||
# ../../../usr/share/%{name}/conf.avail/name
|
||||
%link_avail_to_system_fontsconf() \
|
||||
if [ "x%1" == "x%%1" ]; then \
|
||||
echo "Missing argument in call to %%link_avail_to_system_fontsconf: name of configuration file." \
|
||||
false \
|
||||
fi \
|
||||
echo "Linking available configuration in %{_fontsconfavaildir}/%1 to %{_fontsconfddir}/%1" \
|
||||
mkdir -p "%{buildroot}%{_fontsconfddir}" \
|
||||
ln -s "../../..%{_fontsconfavaildir}/%1" "%{buildroot}%{_fontsconfddir}" \
|
||||
%nil
|
||||
|
||||
# macro: install_fontsconf
|
||||
# takes exactly one argument; for given file (path/to/01-font.conf), it
|
||||
# 1. creates %{_fontsconfavaildir}
|
||||
# 2. copies path/to/01-font.conf to %{_fontsconfavaildir}
|
||||
# uses %link_avail_to_system_fontsconf to
|
||||
# 3. create %{_fontsconfddir}
|
||||
# 4. link %{_fontsavaildir}/01-fonts.conf %{_fontsconfddir}
|
||||
|
||||
%install_fontsconf() \
|
||||
if [ "x%1" == "x%%1" ]; then \
|
||||
echo "Missing argument in call to %%install_fontsconf: path and name of configuration file." \
|
||||
false \
|
||||
fi \
|
||||
mkdir -p "%{buildroot}%{_fontsconfavaildir}" \
|
||||
install -m 644 -p "%1" "%{buildroot}%{_fontsconfavaildir}" \
|
||||
conffile=`basename %1` \
|
||||
%link_avail_to_system_fontsconf $conffile \
|
||||
%nil
|
||||
|
||||
# macro: files_fontsconf_availdir
|
||||
# packages /usr/share/%{name}/conf.avail directory,
|
||||
# which is intended for fontconfig files shipped by the
|
||||
# (font) package
|
||||
|
||||
%files_fontsconf_availdir() \
|
||||
%dir %{_datadir}/%{name} \
|
||||
%dir %{_fontsconfavaildir} \
|
||||
%nil
|
||||
|
||||
# macro: files_fontsconf_file
|
||||
# takes exactly one argument; for given fontconfig file
|
||||
# (01-fontconfig.conf) macro expands in correct %%files entry
|
||||
#
|
||||
# -l option also packages %%{_fontsconfddir}/01-fontconfig.conf link
|
||||
|
||||
%files_fontsconf_file(l) \
|
||||
%{_fontsconfavaildir}/%1 \
|
||||
%{-l: \
|
||||
%config %{_fontsconfddir}/%1 \
|
||||
} \
|
||||
%nil
|
||||
|
||||
# macro: reconfigure_fonts_prereq
|
||||
# adds requires for fonts-config
|
||||
%reconfigure_fonts_prereq \
|
||||
Requires(pre): perl aaa_base \
|
||||
Requires(post): coreutils \
|
||||
Requires(postun): coreutils \
|
||||
Requires(posttrans): coreutils \
|
||||
%nil
|
||||
|
||||
|
||||
# macro: reconfigure_fonts
|
||||
# font setup for suse
|
||||
%reconfigure_fonts \
|
||||
if test -x /usr/sbin/fonts-config ; then \
|
||||
LC_ALL=POSIX \
|
||||
/usr/sbin/fonts-config --quiet \
|
||||
fi \
|
||||
%nil
|
||||
|
||||
|
||||
# macro: reconfigure_fonts
|
||||
# cjk font setup for suse
|
||||
%reconfigure_fonts_cjk \
|
||||
if test -x /usr/sbin/acroread-cidfont-config ; then \
|
||||
/usr/sbin/acroread-cidfont-config \
|
||||
fi \
|
||||
if test -x /usr/sbin/ghostscript-cjk-config ; then \
|
||||
/usr/sbin/ghostscript-cjk-config \
|
||||
fi \
|
||||
%nil
|
||||
|
||||
|
||||
# macro: reconfigure_fonts_post
|
||||
# now alias to reconfigure_fonts, this can change in the future
|
||||
# options:
|
||||
# -c (the fonts are CJK fonts, also do setup which is only needed
|
||||
# for CJK)
|
||||
%reconfigure_fonts_post(c) \
|
||||
mkdir -p `dirname %{__fontsconfigrunflag}` \
|
||||
touch %{__fontsconfigrunflag} \
|
||||
%{-c: \
|
||||
touch %{__fontsconfigrunflag}-cjk \
|
||||
} \
|
||||
%nil
|
||||
|
||||
# macro: reconfigure_fonts_postun
|
||||
# now alias to reconfigure_fonts, this can change in the future
|
||||
# options:
|
||||
# -c (the fonts are CJK fonts, also do setup which is only needed
|
||||
# for CJK)
|
||||
%reconfigure_fonts_postun(c) \
|
||||
if [ $1 -eq 0 ]; then \
|
||||
%reconfigure_fonts \
|
||||
%{-c: \
|
||||
%reconfigure_fonts_cjk \
|
||||
} \
|
||||
fi \
|
||||
%nil
|
||||
|
||||
# macro: reconfigure_fonts_post
|
||||
# do nothing for now, this can change in the future
|
||||
# options:
|
||||
# -c (the fonts are CJK fonts, also do setup which is only needed
|
||||
# for CJK)
|
||||
%reconfigure_fonts_posttrans \
|
||||
if [ -e %{__fontsconfigrunflag} ]; then \
|
||||
%reconfigure_fonts \
|
||||
rm %{__fontsconfigrunflag} \
|
||||
fi \
|
||||
if [ -e %{__fontsconfigrunflag}-cjk ]; then \
|
||||
%reconfigure_fonts_cjk \
|
||||
rm %{__fontsconfigrunflag}-cjk \
|
||||
fi \
|
||||
%nil
|
||||
|
||||
# macro: reconfigure_fonts_scriptles
|
||||
# groups %post, %postun and %posttrans of font packages
|
||||
# options:
|
||||
# -c (the fonts are CJK fonts, also do setup which is only needed
|
||||
# for CJK)
|
||||
# -n <name> (name of subpackage; when ommited, also no -n parameter
|
||||
# is passed to %post, %postun and %posttrans)
|
||||
%reconfigure_fonts_scriptlets(c,n:) \
|
||||
%post %{-n:-n %{-n*}} \
|
||||
%reconfigure_fonts_post c \
|
||||
\
|
||||
%postun %{-n:-n %{-n*}} \
|
||||
%reconfigure_fonts_postun c \
|
||||
\
|
||||
%posttrans %{-n:-n %{-n*}} \
|
||||
%reconfigure_fonts_posttrans \
|
||||
\
|
||||
%nil
|
Loading…
Reference in New Issue
Block a user