Upgrade to 1.00 release
[platform/upstream/monotype-fonts.git] / packaging / monotype-fonts.spec
1 %define _fontsdir               %{_datadir}/fonts
2 %define _ttffontsdir            %{_fontsdir}/truetype
3 %define _miscfontsdir           %{_fontsdir}/misc
4 %define _fontsconfdir           %{_sysconfdir}/fonts
5 %define _fontsconfddir          %{_fontsconfdir}/conf.d
6 %define _fontsconfavaildir      %{_datadir}/%{name}/conf.avail
7
8 Name:           monotype-fonts
9 Version:        1.00
10 Release:        0
11 License:        Apache-2.0
12 Summary:        Fonts package that provides the Clear Sans font
13 Url:            https://01.org/clear-sans
14 Group:          Graphics & UI Framework/Fonts
15 # Upstream only provides a zip file, so source is imported manually
16 Source:         %{name}-%{version}.tar.xz
17 Source1001:     monotype-fonts.manifest
18 BuildArch:      noarch
19 Requires(post): %{_bindir}/fc-cache
20
21 %description
22 Fonts package that provides the Clear Sans font
23
24 %prep
25 %setup -q
26 cp %{SOURCE1001} .
27
28 %build
29
30 %install
31 mkdir -p %{buildroot}%{_ttffontsdir}
32 install -m 0644 TTF/*.ttf %{buildroot}%{_ttffontsdir}/
33
34 %post
35 if [ -x %{_bindir}/fc-cache ]; then
36     %{_bindir}/fc-cache %{_ttffontsdir} || :
37 fi
38
39 %postun
40 if [ -x %{_bindir}/fc-cache ]; then
41     %{_bindir}/fc-cache %{_ttffontsdir} || :
42 fi
43
44 %files
45 %manifest %{name}.manifest
46 %license LICENSE-2.0.txt
47 %{_ttffontsdir}/*.ttf