RHEL 9.0.0 Alpha bootstrap

The content of this branch was automatically imported from Fedora ELN
with the following as its source:
https://src.fedoraproject.org/rpms/xorg-x11-font-utils#b2dae69a8379225c444cf48200912739fb5cf151
This commit is contained in:
Troy Dawson 2020-10-15 14:10:29 -07:00
parent 5548ad2aae
commit 611708f464
6 changed files with 293 additions and 0 deletions

5
.gitignore vendored
View File

@ -0,0 +1,5 @@
fonttosfnt-*.tar.bz2
bdftopcf-*.tar.bz2
mkfontscale-*.tar.bz2
mkfontdir-*.tar.bz2
font-util-*.tar.bz2

View File

@ -0,0 +1,13 @@
diff --git a/mkfontscale.c b/mkfontscale.c
index a67f283..96e19a3 100644
--- a/mkfontscale.c
+++ b/mkfontscale.c
@@ -317,7 +317,7 @@ getName(FT_Face face, int nid)
int i;
if(getNameHelper(face, nid,
- TT_PLATFORM_MICROSOFT, TT_MS_ID_UNICODE_CS, &name) ||
+ TT_PLATFORM_MICROSOFT, -1, &name) ||
getNameHelper(face, nid,
TT_PLATFORM_APPLE_UNICODE, -1, &name)) {
string = malloc(name.string_len / 2 + 1);

6
sources Normal file
View File

@ -0,0 +1,6 @@
SHA512 (bdftopcf-1.1.tar.bz2) = 7b790e8d512ca2812ac889c156ef91c48798b4744a6857e5b17e0128764b5afa8c5426fe5de05a9819d64745116718db4221b3e657e3c2633465e87179c44bec
SHA512 (font-util-1.3.1.tar.bz2) = 9fd6dd4c0a01ede5f0b09ec0f9d316267ca086e2ee9526a43a4e4d6ce3cd67c977293bd3cf440328ca417292fcae1579888b24b7259eaf012230890210d74889
SHA512 (mkfontdir-1.0.7.tar.bz2) = 96d1920565514f90621e18a87fb5a2db9e052d1bffc6552d9659e065a21e252ab98b4e62013755032b98ed6d8c3381eb75c3c8e02651766ee4791ca622dcef1f
SHA512 (mkfontscale-1.1.3.tar.bz2) = 509e2f9cd55cf87cc3968c8767bf3f2386016278db8b7be75b7df34bf61f52519dd2778f3b9881ffbe30cc2fe26089c0a5b2c33af46bc7727f46dad83f030a62
SHA512 (fonttosfnt-1.0.5.tar.bz2) = dba990098c95b07bc7240699a5c9ea11f056fbfddd70f669ae283548cbf20d756b28d817a99548c23ba81de9792877296ab6f35ee3c630e5c3cd8f14650ce297
SHA512 (fonttosfnt-1.1.0.tar.bz2) = f4fb9814c23bfd6f83771959444d2c37eb4ba32edee43c37cf21f0181be80c6e278307641b0f4dae4ee5d10db3289e95194f99757ea4bbca343fff15498e7173

185
xorg-x11-font-utils.spec Normal file
View File

@ -0,0 +1,185 @@
%global bdftopcf 1.1
%global fonttosfnt 1.1.0
%global mkfontdir 1.0.7
%global mkfontscale 1.1.3
%global font_util 1.3.1
# Must be kept in sync with xorg-x11-fonts!
%global _x11fontdir %{_datadir}/X11/fonts
Summary: X.Org X11 font utilities
Name: xorg-x11-font-utils
Epoch: 1
Version: 7.5
Release: 45%{?dist}
License: MIT
URL: http://www.x.org
Source0: http://www.x.org/pub/individual/app/bdftopcf-%{bdftopcf}.tar.bz2
Source1: http://www.x.org/pub/individual/app/fonttosfnt-%{fonttosfnt}.tar.bz2
Source2: http://www.x.org/pub/individual/app/mkfontdir-%{mkfontdir}.tar.bz2
Source3: http://www.x.org/pub/individual/app/mkfontscale-%{mkfontscale}.tar.bz2
Source4: http://www.x.org/pub/individual/font/font-util-%{font_util}.tar.bz2
# helper script used in post for xorg-x11-fonts
Source5: xorg-x11-fonts-update-dirs
Source6: xorg-x11-fonts-update-dirs.1
Patch0: mkfontscale-examine-all-encodings.patch
BuildRequires: libtool
BuildRequires: pkgconfig(fontenc)
BuildRequires: pkgconfig(freetype2)
BuildRequires: pkgconfig(x11)
BuildRequires: pkgconfig(xorg-macros) >= 1.8
BuildRequires: zlib-devel
Provides: bdftopcf = %{bdftopcf}
Provides: fonttosfnt = %{fonttosfnt}
Provides: mkfontdir = %{mkfontdir}
Provides: mkfontscale = %{mkfontscale}
Provides: font-util = %{font_util}
Provides: font-utils = %{epoch}:%{version}-%{release}
Provides: ucs2any = %{font_util}
%description
X.Org X11 font utilities required for font installation, conversion, and
generation.
%prep
%setup -q -c %{name}-%{version} -a1 -a2 -a3 -a4
pushd mkfontscale-*
%patch0 -p1 -b .all-encodings
popd
%build
# Build all apps
{
for app in * ; do
pushd $app
autoreconf -vif
case $app in
font-util-*)
%configure --with-fontrootdir=%{_x11fontdir}
;;
*)
%configure
;;
esac
make %{?_smp_mflags}
popd
done
}
%install
# Install all apps
{
for app in * ; do
pushd $app
%make_install
popd
done
for i in */README ; do
[ -s $i ] && cp $i README-$(echo $i | sed 's/-[0-9].*//')
done
for i in */COPYING ; do
grep -q stub $i || cp $i COPYING-$(echo $i | sed 's/-[0-9].*//')
done
}
install -m 744 %{SOURCE5} $RPM_BUILD_ROOT%{_bindir}/xorg-x11-fonts-update-dirs
sed -i "s:@DATADIR@:%{_datadir}:" $RPM_BUILD_ROOT%{_bindir}/xorg-x11-fonts-update-dirs
install -m 744 -p -D %{SOURCE6} $RPM_BUILD_ROOT%{_mandir}/man1/xorg-x11-fonts-update-dirs.1
find $RPM_BUILD_ROOT -name bdftruncate\* -print0 | xargs -0 rm -f
%files
%doc README-* COPYING-bdftopcf COPYING-[c-z]*
%{_bindir}/bdftopcf
%{_bindir}/fonttosfnt
%{_bindir}/mkfontdir
%{_bindir}/mkfontscale
%{_bindir}/ucs2any
%{_bindir}/xorg-x11-fonts-update-dirs
%{_datadir}/aclocal/fontutil.m4
%{_libdir}/pkgconfig/fontutil.pc
%{_mandir}/man1/bdftopcf.1*
%{_mandir}/man1/fonttosfnt.1*
%{_mandir}/man1/mkfontdir.1*
%{_mandir}/man1/mkfontscale.1*
%{_mandir}/man1/ucs2any.1*
%{_mandir}/man1/xorg-x11-fonts-update-dirs.1*
%dir %{_x11fontdir}
%dir %{_x11fontdir}/util
%{_x11fontdir}/util/map-*
%changelog
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1:7.5-45
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
* Fri Jan 31 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1:7.5-44
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
* Mon Jan 06 2020 Peter Hutterer <peter.hutterer@redhat.com> 1:7.5-43
- fonttosfnt 1.1.0
* Sat Jul 27 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1:7.5-42
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
* Sun Feb 03 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1:7.5-41
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
* Wed Aug 01 2018 Peter Hutterer <peter.hutterer@redhat.com> 1:7.5-40
- fonttosfnt 1.0.5
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1:7.5-39
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
* Thu May 17 2018 Peter Hutterer <peter.hutterer@redhat.com> 1:7.5-38
- mkfontscale 1.1.3
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1:7.5-37
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
* Thu Jan 25 2018 Adam Jackson <ajax@redhat.com> - 7.5-36
- bdftopcf 1.1
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1:7.5-35
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1:7.5-34
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1:7.5-33
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
* Wed Sep 28 2016 Hans de Goede <hdegoede@redhat.com> - 1:7.5-32
- bdftopcf 1.0.5
* Fri Feb 05 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1:7.5-31
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
* Wed Jan 20 2016 Peter Hutterer <peter.hutterer@redhat.com>
- s/define/global/
* Thu Oct 15 2015 Adam Jackson <ajax@redhat.com> 7.5-30
- Drop bdftruncate utility, nothing in the OS uses it and we don't ship BDF
fonts in any case.
* Fri Jun 19 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:7.5-29
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
* Fri May 01 2015 Simone Caronni <negativo17@gmail.com> - 1:7.5-28
- font-util 1.3.1
* Sat Feb 21 2015 Till Maas <opensource@till.name> - 1:7.5-27
- Rebuilt for Fedora 23 Change
https://fedoraproject.org/wiki/Changes/Harden_all_packages_with_position-independent_code
* Sat Jan 17 2015 Simone Caronni <negativo17@gmail.com> - 1:7.5-26
- Update mkfontscale to 1.1.2.
* Mon Nov 10 2014 Simone Caronni <negativo17@gmail.com> - 1:7.5-25
- Restore font-utils provider, required by some packages for building.
examine all platform=3 encodings (fixes #578460)

61
xorg-x11-fonts-update-dirs Executable file
View File

@ -0,0 +1,61 @@
#!/bin/sh
# This script is used by the xorg-x11-fonts package in the %post stage for
# some fonts to generate the right encodings.
fontdir=""
encodingsdir="@DATADIR@/X11/fonts/encodings"
# some fonts need to skip mkfontscale, set to "yes" to skip
skip_fontscale=""
# some fonts need to run ttmkfdir, set to "yes" to run
need_ttmkfdir=""
if [ $# -lt 1 ]; then
echo "Need at least one parameter for font dir."
exit 1
fi
while [ $# != 0 ]; do
case $1 in
--skip-fontscale)
skip_fontscale="yes"
;;
--need-ttmkfdir)
need_ttmkfdir="yes"
;;
--encodingsdir)
shift
encodingsdir="$1"
;;
*)
fontdir="$1"
if [ $# != 1 ]; then
echo "Too many parameters."
exit 1
fi
;;
esac
shift
done
if [ "$skip_fontscale" != "yes" ]; then
mkfontscale $fontdir
fi
if [ "$need_ttmkfdir" = "yes" ]; then
ttmkfdir -d $fontdir -o "$fontdir/fonts.scale"
fi
mkfontdir $fontdir
fc-cache $fontdir
if ! [ -z "$encodingsdir" ]; then
[ -d "$encodingsdir" ] || mkdir -p "$encodingsdir"
[ -d "$encodingsdir/large" ] || mkdir -p "$encodingsdir/large"
oldpwd=$(pwd)
cd "$encodingsdir"
mkfontscale -n -e "$encodingsdir" -e "$encodingsdir/large"
cd ${oldpwd}
fi

View File

@ -0,0 +1,23 @@
.TH XORG-X11-FONTS-UPDATE-DIRS 1 "25 July 2014"
.SH NAME
xorg-x11-fonts-update-dirs \- update X11 font directories
.SH SYNOPSIS
.B xorg-x11-fonts-update-dirs [--skip-fontscale] [--need-ttmkfdir] path
.SH DESCRIPTION
.PP
The
.B xorg-x11-fonts-*
rpm packages call
.I xorg-x11-fonts-update-dirs
during %post and %postun to update the X11 font indices.
This script may change in incompatible ways without notice and
you should not run this script manually or rely on it otherwise.
To manually update the font indices invoke
.B mkfontscale
and
.B ttmkfdir
directly as required.
.PP
.SH "SEE ALSO"
mkfontscale(1)
ttmkfdir(1)