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