Blame SPECS/paratype-pt-sans-fonts.spec

405e14
%global fontname paratype-pt-sans
405e14
%global fontconf 57-%{fontname}
405e14
405e14
%global archivename PTSans.zip
405e14
405e14
%global common_desc \
405e14
The PT Sans family was developed as part of the “Public Types of Russian \
405e14
Federation” project. This project aims at enabling the peoples of Russia to \
405e14
read and write their native languages, using free/libre fonts. It is \
405e14
dedicated to the 300-year anniversary of the Russian civil type invented by \
405e14
Peter the Great from 1708 to 1710, and was realized with financial support \
405e14
from the Russian Federal Agency for Press and Mass Communications. \
405e14
\
405e14
The fonts include support for all 54 title¹ languages of the Russian \
405e14
Federation as well as more common Western, Central European and Cyrillic \
405e14
blocks making them unique and a very important tool for modern digital \
405e14
communications. \
405e14
\
405e14
PT Sans is a grotesque font based on Russian type designs of the second part \
405e14
of the 20th century. However, it also includes very distinctive features of \
405e14
modern humanistic design, fulfilling present day aesthetic and functional \
405e14
requirements. \
405e14
\
405e14
It was designed by Alexandra Korolkova, Olga Umpeleva and Vladimir Yefimov \
405e14
and released by ParaType. \
405e14
\
405e14
¹ A “title” language is named after an ethnic group.
405e14
405e14
405e14
Name:           %{fontname}-fonts
405e14
Version:        20141121
405e14
Release:        6%{?dist}
405e14
Summary:        A pan-Cyrillic typeface
405e14
405e14
License:        OFL
405e14
URL:            http://www.paratype.com/public/
405e14
# We now got new updated source archive to use
405e14
Source0:        http://www.fontstock.com/public/PTSansOFL.zip
405e14
# Below is original and old source archive
405e14
# Source0:        http://www.fontstock.com/public/PTSans_OFL.zip
405e14
Source10:       %{name}-fontconfig.conf
405e14
Source11:       %{name}-caption-fontconfig.conf
405e14
Source12:       %{fontname}.metainfo.xml
405e14
Source13:       %{fontname}-narrow.metainfo.xml
405e14
Source14:       %{fontname}-caption.metainfo.xml
405e14
405e14
BuildArch:      noarch
405e14
Requires:       fontpackages-filesystem
405e14
BuildRequires:  fontpackages-devel
405e14
405e14
%description
405e14
%common_desc
405e14
405e14
This package includes the four basic styles and two narrows styles for
405e14
economic setting.
405e14
405e14
%_font_pkg -f %{fontconf}.conf PTS*.ttf PTN*.ttf
405e14
%doc *.txt
405e14
%{_datadir}/appdata/%{fontname}.metainfo.xml
405e14
%{_datadir}/appdata/%{fontname}-narrow.metainfo.xml
405e14
405e14
405e14
%package -n %{fontname}-caption-fonts
405e14
Summary:        A pan-Cyrillic typeface (caption forms for small text)
405e14
BuildRequires:  fontpackages-devel
405e14
405e14
%description -n %{fontname}-caption-fonts
405e14
%common_desc
405e14
405e14
This package includes 2 captions styles for small text sizes.
405e14
405e14
%_font_pkg -n caption -f %{fontconf}-caption.conf PTC*.ttf
405e14
%doc *.txt
405e14
%{_datadir}/appdata/%{fontname}-caption.metainfo.xml
405e14
405e14
405e14
%prep
405e14
%setup -q -c
405e14
405e14
for txt in *.txt ; do
405e14
   if $(echo "$txt" | grep -q "rus\.txt") ; then
405e14
     iconv --from=UTF-16       --to=UTF-8 "$txt" > "$txt.1"
405e14
   else
405e14
     iconv --from=WINDOWS-1251 --to=UTF-8 "$txt" > "$txt.1"
405e14
   fi
405e14
   sed -i 's/\r//' "$txt.1"
405e14
   touch -r "$txt" "$txt.1"
405e14
   mv "$txt.1" "$txt"
405e14
done
405e14
405e14
405e14
%build
405e14
405e14
405e14
%install
405e14
install -m 0755 -d %{buildroot}%{_fontdir}
405e14
install -m 0644 -p *.ttf %{buildroot}%{_fontdir}
405e14
405e14
install -m 0755 -d %{buildroot}%{_fontconfig_templatedir} \
405e14
                   %{buildroot}%{_fontconfig_confdir}
405e14
405e14
install -m 0644 -p %{SOURCE10} \
405e14
        %{buildroot}%{_fontconfig_templatedir}/%{fontconf}.conf
405e14
install -m 0644 -p %{SOURCE11} \
405e14
        %{buildroot}%{_fontconfig_templatedir}/%{fontconf}-caption.conf
405e14
405e14
for fconf in %{fontconf}.conf \
405e14
             %{fontconf}-caption.conf ; do
405e14
  ln -s %{_fontconfig_templatedir}/$fconf \
405e14
        %{buildroot}%{_fontconfig_confdir}/$fconf
405e14
done
405e14
405e14
# Add AppStream metadata
405e14
install -Dm 0644 -p %{SOURCE12} \
405e14
        %{buildroot}%{_datadir}/appdata/%{fontname}.metainfo.xml
405e14
install -Dm 0644 -p %{SOURCE13} \
405e14
        %{buildroot}%{_datadir}/appdata/%{fontname}-narrow.metainfo.xml
405e14
install -Dm 0644 -p %{SOURCE14} \
405e14
        %{buildroot}%{_datadir}/appdata/%{fontname}-caption.metainfo.xml
405e14
405e14
405e14
%changelog
405e14
* Thu Feb 08 2018 Fedora Release Engineering <releng@fedoraproject.org> - 20141121-6
405e14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
405e14
405e14
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 20141121-5
405e14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
405e14
405e14
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 20141121-4
405e14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
405e14
405e14
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 20141121-3
405e14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
405e14
405e14
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 20141121-2
405e14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
405e14
405e14
* Fri Nov 21 2014 Parag Nemade <pnemade AT redhat DOT com> - 20141121-1
405e14
- Change the Source0 archive
405e14
- Update to current snapshot 20141121
405e14
405e14
* Sun Nov 09 2014 Parag Nemade <pnemade AT redhat DOT com> - 20101909-5
405e14
- Add metainfo file to show this font in gnome-software
405e14
- Remove group tag
405e14
405e14
* Fri Jun 06 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 20101909-4
405e14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
405e14
405e14
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 20101909-3
405e14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
405e14
405e14
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 20101909-2
405e14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
405e14
405e14
* Fri Nov 30 2012 Parag <paragn AT fedoraproject DOT org> - 20101909-1
405e14
- Resolves:rh#882107 - source files does not match with upstream
405e14
405e14
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 20100408-4
405e14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
405e14
405e14
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 20100408-3
405e14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
405e14
405e14
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 20100408-2
405e14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
405e14
405e14
* Sun Jul 25 2010 Nicolas Mailhot <nicolas.mailhot at laposte.net>
405e14
- 20100408-1
405e14
— Update to latest upstream release
405e14
— Switch to the OFL version
405e14
405e14
* Thu Feb 18 2010 Nicolas Mailhot <nicolas.mailhot at laposte.net>
405e14
- 20100112-3
405e14
— Remove vestigial dep in caption subpackage
405e14
405e14
* Sat Feb 13 2010 Nicolas Mailhot <nicolas.mailhot at laposte.net>
405e14
- 20100112-2
405e14
— Update for review
405e14
405e14
* Sun Jan 17 2010 Nicolas Mailhot <nicolas.mailhot at laposte.net>
405e14
- 20100112-1
405e14
— Initial release
405e14