Convert to new fonts packaging guidelines
This commit is contained in:
parent
7f20d4be4e
commit
b1f80f3c8c
@ -1,72 +1,58 @@
|
||||
%global fontname madan
|
||||
%global fontconf 65-0-%{fontname}.conf
|
||||
BuildRequires: fontforge
|
||||
|
||||
Name: %{fontname}-fonts
|
||||
Version: 2.000
|
||||
Release: 25%{?dist}
|
||||
Summary: Font for Nepali language
|
||||
License: GPL+
|
||||
Release: 26%{?dist}
|
||||
URL: http://madanpuraskar.org/
|
||||
|
||||
%global fontlicense GPL+
|
||||
%global fontlicenses license.txt
|
||||
|
||||
%global fontfamily Madan
|
||||
%global fontsummary Font for Nepali language
|
||||
%global fonts madan.ttf
|
||||
%global fontconfs %{SOURCE1}
|
||||
%global fontdescription %{expand:
|
||||
This package provides the Madan font for Nepali made by the
|
||||
Madan Puraskar Pustakalaya project.}
|
||||
|
||||
# Found new following working Source URL. Use wget to download this archive
|
||||
Source0: http://ltk.org.np/downloads/fonts.zip
|
||||
Source1: %{name}-fontconfig.conf
|
||||
Source1: 65-0-%{fontpkgname}.conf
|
||||
# Extract from font info
|
||||
Source2: license.txt
|
||||
Source3: sfd2ttf.pe
|
||||
Source4: %{fontname}.metainfo.xml
|
||||
# Below files will make sure "fc-scan madan.ttf |grep lang:" will show ne
|
||||
Source5: madan.py
|
||||
Source6: madan_u0970_glyph.svg
|
||||
BuildArch: noarch
|
||||
BuildRequires: fontforge
|
||||
BuildRequires: fontpackages-devel
|
||||
Requires: fontpackages-filesystem
|
||||
Source4: madan.py
|
||||
Source5: madan_u0970_glyph.svg
|
||||
|
||||
%description
|
||||
This package provides the Madan font for Nepali made by the
|
||||
Madan Puraskar Pustakalaya project.
|
||||
%fontpkg
|
||||
|
||||
%prep
|
||||
%autosetup -c
|
||||
cp -p %{SOURCE2} %{SOURCE3} \
|
||||
%{SOURCE5} %{SOURCE6} .
|
||||
%{SOURCE4} %{SOURCE5} .
|
||||
|
||||
for file in license.txt; do
|
||||
sed "s|\r||g" $file > $file.new && \
|
||||
touch -r $file $file.new && \
|
||||
mv $file.new $file
|
||||
done
|
||||
|
||||
cp -p %{SOURCE2} %{SOURCE4} %{SOURCE5} .
|
||||
%linuxtext license.txt
|
||||
|
||||
chmod 755 sfd2ttf.pe madan.py
|
||||
./madan.py madan.ttf madan_u0970_glyph.svg
|
||||
./sfd2ttf.pe madan.sfd
|
||||
|
||||
%build
|
||||
echo "Nothing to do in Build."
|
||||
%fontbuild
|
||||
|
||||
%install
|
||||
install -m 0755 -d %{buildroot}%{_fontdir}
|
||||
install -m 0644 -p madan.ttf %{buildroot}%{_fontdir}
|
||||
%fontinstall
|
||||
|
||||
install -m 0755 -d %{buildroot}%{_fontconfig_templatedir} \
|
||||
%{buildroot}%{_fontconfig_confdir}
|
||||
%check
|
||||
%fontcheck
|
||||
|
||||
install -m 0644 -p %{SOURCE1} \
|
||||
%{buildroot}%{_fontconfig_templatedir}/%{fontconf}
|
||||
ln -s %{_fontconfig_templatedir}/%{fontconf} \
|
||||
%{buildroot}%{_fontconfig_confdir}/%{fontconf}
|
||||
|
||||
# Add AppStream metadata
|
||||
install -Dm 0644 -p %{SOURCE3} \
|
||||
%{buildroot}%{_datadir}/appdata/%{fontname}.metainfo.xml
|
||||
|
||||
%_font_pkg -f %{fontconf} *.ttf
|
||||
%doc license.txt
|
||||
%{_datadir}/appdata/%{fontname}.metainfo.xml
|
||||
%fontfiles
|
||||
|
||||
%changelog
|
||||
* Tue Mar 10 2020 Parag Nemade <pnemade AT redhat DOT com> - 2.000-26
|
||||
- Convert to new fonts packaging guidelines
|
||||
|
||||
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2.000-25
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
||||
|
||||
|
@ -1,16 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!-- Copyright 2014 Parag Nemade <pnemade AT redhat DOT com> -->
|
||||
<component type="font">
|
||||
<id>madan</id>
|
||||
<metadata_license>CC-BY-3.0</metadata_license>
|
||||
<name>Madan</name>
|
||||
<summary>Font for Nepali language</summary>
|
||||
<description>
|
||||
<p>
|
||||
This package provides the Madan font for Nepali made by the
|
||||
Madan Puraskar Pustakalaya project.
|
||||
</p>
|
||||
</description>
|
||||
<updatecontact>pnemade_at_redhat_dot_com</updatecontact>
|
||||
<url type="homepage">http://madanpuraskar.org/</url>
|
||||
</component>
|
Loading…
Reference in New Issue
Block a user