From e6609604a2636a7869f1a9fbec8f8e18eaf01763 Mon Sep 17 00:00:00 2001 From: Parag Nemade Date: Sat, 3 Sep 2022 12:23:52 +0530 Subject: [PATCH] Convert spec to new fonts packaging guidelines Update to new upstream release 0.117 Signed-off-by: Parag Nemade --- .gitignore | 1 + amiri-fontconfig.conf => 67-amiri-fonts.conf | 2 +- ...ntconfig.conf => 67-amiri-quran-fonts.conf | 2 +- amiri-fonts.spec | 145 ++++++++---------- sources | 2 +- 5 files changed, 68 insertions(+), 84 deletions(-) rename amiri-fontconfig.conf => 67-amiri-fonts.conf (86%) rename amiri-quran-fontconfig.conf => 67-amiri-quran-fonts.conf (86%) diff --git a/.gitignore b/.gitignore index a250618..62e8017 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ /Amiri-0.111.zip /Amiri-0.112.zip /Amiri-0.113.zip +/Amiri-0.117.zip diff --git a/amiri-fontconfig.conf b/67-amiri-fonts.conf similarity index 86% rename from amiri-fontconfig.conf rename to 67-amiri-fonts.conf index e7eaca6..1824342 100644 --- a/amiri-fontconfig.conf +++ b/67-amiri-fonts.conf @@ -1,5 +1,5 @@ - + serif diff --git a/amiri-quran-fontconfig.conf b/67-amiri-quran-fonts.conf similarity index 86% rename from amiri-quran-fontconfig.conf rename to 67-amiri-quran-fonts.conf index 3fc0817..3de7979 100644 --- a/amiri-quran-fontconfig.conf +++ b/67-amiri-quran-fonts.conf @@ -1,5 +1,5 @@ - + serif diff --git a/amiri-fonts.spec b/amiri-fonts.spec index 7fac9c2..b38962f 100644 --- a/amiri-fonts.spec +++ b/amiri-fonts.spec @@ -1,111 +1,95 @@ -%global fontname amiri - -%global common_desc \ -Amiri is a classical Arabic typeface in Naskh style for typesetting books \ -and other running text. \ - \ -Amiri is a revival of the beautiful typeface pioneered in early 20th \ -century by Bulaq Press in Cairo, also known as Amiria Press, after which \ +Version: 0.117 +Release: 1%{?dist} +URL: http://www.amirifont.org + +%global fontlicense OFL-1.1 +%global fontlicenses OFL.txt +%global fontdocs README.md README-Arabic.md Documentation-Arabic.html +%global fontdocsex %{fontlicenses} + +%global common_description %{expand: +Amiri is a revival of the beautiful typeface pioneered in early 20th +century by Bulaq Press in Cairo, also known as Amiria Press, after which the font is named. +} -%global common_desc_ar \ -الخط الأميري خط نسخي موجه لطباعة الكتب والنصوص الطويلة. \ -الخط الأميري هو إحياء ومحاكاة للخط الطباعي الجميل الذي \ -تميزت به مطبعة بولاق منذ أوائل القرن العشرين، والتي عرفت \ +%global common_description_ar %{expand: +تميزت به مطبعة بولاق منذ أوائل القرن العشرين، والتي عرفت أيضًا بالمطبعة الأميرية، ومن هنا أخذ الخط اسمه. +} -Name: %{fontname}-fonts -Version: 0.113 -Release: 4%{?dist} -License: OFL +%global fontfamily0 Amiri +%global fontsummary0 A classical Arabic font in Naskh style +%global fontpkgheader0 %{expand: +Obsoletes: amiri-fonts-common < %{version}-%{release} +} +%global fonts0 Amiri-Regular.ttf Amiri-Slanted.ttf Amiri-BoldSlanted.ttf Amiri-Bold.ttf +%global fontconfs0 %{SOURCE10} +%global fontdescription0 %{expand:%{common_description} -Source0: https://github.com/alif-type/amiri/releases/download/%{version}/Amiri-%{version}.zip -Source1: %{fontname}-quran-fontconfig.conf -Source2: %{fontname}-fontconfig.conf +Amiri is a classical Arabic typeface in Naskh style for typesetting books +and other running text. +%{common_description_ar} -BuildArch: noarch -BuildRequires: fontpackages-devel -Requires: %{name}-common = %{version}-%{release} +الخط الأميري خط نسخي موجه لطباعة الكتب والنصوص الطويلة. +الخط الأميري هو إحياء ومحاكاة للخط الطباعي الجميل الذي -Summary: A classical Arabic font in Naskh style -Summary(ar): الخطوط الأميرية ذات المظهر الأنيق و التّراث العريق -URL: http://www.amirifont.org +} -%description -%common_desc +%global fontfamily1 Amiri Quran +%global fontsummary1 Quran type of Amiri fonts +%global fonts1 AmiriQuran.ttf +%global fontconfs1 %{SOURCE11} +%global fontdescription1 %{expand:%{common_description} -%description -l ar -%common_desc_ar +This package contains Quran type of Amiri fonts. -%package common +%{common_description_ar} -Summary: Common files for %{name} -Summary(ar): الملفات العامّة للخطوط الأميرية -Requires: fontpackages-filesystem +تحتوي هذه الحُزمة على النّمط القرآني من الخط الأميري. +} -%description common -%common_desc +%global fontfamily2 Amiri Quran Colored +%global fontsummary2 None +%global fonts2 AmiriQuranColored.ttf +%global fontconfs2 %{SOURCE12} +%global fontdescription2 %{expand:%{common_description} +This package contains Quran Colored type of Amiri fonts. -This package consists of files used by other %{name} packages. +%{common_description_ar} -%description common -l ar -%common_desc_ar +تحتوي هذه الحزمة على نوع القرآن الملون من الخطوط الأميرية. +} -تتألف هذه الحزمة من ملفات الخط الأميري العامة. -%package -n %{fontname}-quran-fonts -Summary: Quran type of Amiri fonts -Summary(ar): النّمط القُرآني من الخط الأميري -Requires: %{name}-common = %{version}-%{release} +Source0: https://github.com/alif-type/amiri/releases/download/%{version}/Amiri-%{version}.zip +Source10: 67-%{fontpkgname0}.conf +Source11: 67-%{fontpkgname1}.conf +Source12: 67-%{fontpkgname2}.conf -%description -n %{fontname}-quran-fonts -%common_desc +%fontpkg -a -This package contains Quran type of Amiri fonts. -%description -n %{fontname}-quran-fonts -l ar -%common_desc_ar - -تحتوي هذه الحُزمة على النّمط القرآني من الخط الأميري. +%fontmetapkg %prep %setup -q -n Amiri-%{version} %build -#Nothing to build +%fontbuild -a %install -install -m 0755 -d %{buildroot}%{_fontdir} - -install -m 0644 -p Amiri-Bold.ttf %{buildroot}%{_fontdir}/%{fontname}-bold.ttf -install -m 0644 -p Amiri-BoldSlanted.ttf %{buildroot}%{_fontdir}/%{fontname}-boldslanted.ttf -install -m 0644 -p Amiri-Regular.ttf %{buildroot}%{_fontdir}/%{fontname}-regular.ttf -install -m 0644 -p Amiri-Slanted.ttf %{buildroot}%{_fontdir}/%{fontname}-slanted.ttf -install -m 0644 -p AmiriQuran.ttf %{buildroot}%{_fontdir}/%{fontname}-quran.ttf -install -m 0644 -p AmiriQuranColored.ttf %{buildroot}%{_fontdir}/%{fontname}-quran-colored.ttf - -install -m 0755 -d %{buildroot}%{_fontconfig_templatedir} \ - %{buildroot}%{_fontconfig_confdir} +%fontinstall -a -install -m 0644 -p %{SOURCE1} \ - %{buildroot}%{_fontconfig_templatedir}/67-%{fontname}-quran.conf -install -m 0644 -p %{SOURCE2} \ - %{buildroot}%{_fontconfig_templatedir}/67-%{fontname}.conf +%check +%fontcheck -a -for fontconf in 67-%{fontname}-quran.conf \ - 67-%{fontname}.conf ; do - ln -s %{_fontconfig_templatedir}/$fontconf \ - %{buildroot}%{_fontconfig_confdir}/$fontconf -done - -%_font_pkg -n quran -f 67-%{fontname}-quran.conf amiri-quran.ttf amiri-quran-colored.ttf - -%_font_pkg -f 67-%{fontname}.conf amiri-regular.ttf amiri-slanted.ttf amiri-bold.ttf amiri-boldslanted.ttf - -%files common -%license OFL.txt -%doc NEWS README README-Arabic NEWS-Arabic Documentation-Arabic.pdf +%fontfiles -a %changelog +* Sat Sep 03 2022 Parag Nemade - 0.117-1 +- Convert spec to new fonts packaging guidelines +- Update to new upstream release 0.117 + * Wed Jul 20 2022 Fedora Release Engineering - 0.113-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild @@ -177,7 +161,7 @@ done * Wed Nov 13 2013 Mosaab Alzoubi - 0.106-9 - Change variable font priority to 67 in font_pkg line. - Reform Summary. - + * Mon Nov 11 2013 Mosaab Alzoubi - 0.106-8 - Re-split into main and Quran fonts. - Improve Amiri Quran font config. @@ -223,4 +207,3 @@ done * Mon Dec 19 2011 Ehab El-Gedawy - 0.100-1 - Initial Packaging - diff --git a/sources b/sources index 8d4aa9c..59c132d 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (Amiri-0.113.zip) = c3b65249b42d272ecdc9206687d6213ef376afcb65d43a259d587b34d8d5c39ac3295291a5f9a0d6d614ad890bf238ecd706bf723734253367e765b526ace2b4 +SHA512 (Amiri-0.117.zip) = 7ab081f32726d67dab2b1a4036f180687ce9ab37dc62974c426a21235385085e0bdc0837eb2c74d4aab12c1c0cbbac856558a39c59d9d7e16def187139361daf