]>
Commit | Line | Data |
---|---|---|
f2dd53b0 | 1 | # |
2 | # Conditional build: | |
d9fe5f79 | 3 | %bcond_with license_agreement # generates package (may require MS Office license?) |
f2dd53b0 | 4 | # |
c2e26013 JB |
5 | Summary: Microsoft Arial Unicode TrueType font |
6 | Summary(pl.UTF-8): Font TrueType Arial Unicode firmy Microsoft | |
f2dd53b0 | 7 | %define base_name fonts-TTF-Microsoft-ArialUnicode |
8 | %if %{with license_agreement} | |
9 | Name: %{base_name} | |
10 | %else | |
11 | Name: %{base_name}-installer | |
12 | %endif | |
13 | Version: 1.0 | |
f72a06dd | 14 | Release: 2%{?with_license_agreement:wla} |
f2dd53b0 | 15 | # part of MS Office - may require Office license to use |
16 | License: ? | |
17 | Group: Fonts | |
18 | %if %{with license_agreement} | |
19 | # also at http://dl.sourceforge.net/corefonts/ | |
20 | Source0: http://orwell.ru/download/aruniupd.exe | |
21 | # NoSource0-md5: 1bef548eb449a0b24ad1c0b8e9d5f2ba | |
22 | BuildRequires: cabextract | |
23 | Requires: %{_fontsdir}/TTF | |
24 | Requires(post,postun): fontpostinst | |
25 | %else | |
748ca643 | 26 | Source0: http://svn.pld-linux.org/svn/license-installer/license-installer.sh |
27 | # Source0-md5: 4fb1600353dd57fe088e0b12fb0ecac2 | |
f2dd53b0 | 28 | Requires: cabextract |
748ca643 | 29 | Requires: rpm-build-tools >= 4.4.35 |
f2dd53b0 | 30 | %endif |
31 | BuildArch: noarch | |
32 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
33 | ||
34 | %define ttffontsdir %{_fontsdir}/TTF | |
35 | ||
36 | %description | |
c2e26013 | 37 | Microsoft Arial Unicode TrueType font. |
5b7ab2ca | 38 | %if !%{with license_agreement} |
f2dd53b0 | 39 | License issues made us not to include inherent files into this package |
14f93690 | 40 | by default (it probably requires MS Office license). If you want to |
f2dd53b0 | 41 | create full working package please build it with one of the following |
42 | command: | |
43 | ||
44 | %{base_name}.install --with license_agreement %{_datadir}/%{base_name}/%{base_name}.spec | |
f2dd53b0 | 45 | %endif |
46 | ||
bcb6f4b5 | 47 | %description -l pl.UTF-8 |
c2e26013 | 48 | Font TrueType Arial Unicode firmy Microsoft. |
5b7ab2ca | 49 | %if !%{with license_agreement} |
bcb6f4b5 JR |
50 | Kwestie licencji zmusiły nas do niedołączania do tego pakietu istotnych |
51 | plików (prawdopodobnie wymaga licencji na MS Office). Jeśli chcesz stworzyć | |
52 | w pełni funkcjonalny pakiet, zbuduj go za pomocą polecenia: | |
f2dd53b0 | 53 | |
54 | %{base_name}.install --with license_agreement %{_datadir}/%{base_name}/%{base_name}.spec | |
f2dd53b0 | 55 | %endif |
56 | ||
57 | %prep | |
58 | %if %{with license_agreement} | |
59 | %setup -q -c -T | |
60 | /usr/bin/cabextract -L %{SOURCE0} | |
61 | %endif | |
62 | ||
63 | %install | |
64 | rm -rf $RPM_BUILD_ROOT | |
5b7ab2ca | 65 | %if !%{with license_agreement} |
f2dd53b0 | 66 | install -d $RPM_BUILD_ROOT{%{_bindir},%{_datadir}/%{base_name}} |
67 | ||
f72a06dd ER |
68 | sed -e ' |
69 | s/@BASE_NAME@/%{base_name}/g | |
70 | s/@TARGET_CPU@/%{_target_cpu}/g | |
71 | s-@VERSION@-%{version}-g | |
72 | s-@RELEASE@-%{release}-g | |
73 | s,@SPECFILE@,%{_datadir}/%{base_name}/%{base_name}.spec,g | |
748ca643 | 74 | s,@DATADIR@,%{_datadir}/%{base_name},g |
f72a06dd | 75 | ' %{SOURCE0} > $RPM_BUILD_ROOT%{_bindir}/%{base_name}.install |
f2dd53b0 | 76 | |
77 | install %{_specdir}/%{base_name}.spec $RPM_BUILD_ROOT%{_datadir}/%{base_name} | |
78 | ||
79 | %else | |
80 | install -d $RPM_BUILD_ROOT%{ttffontsdir} | |
81 | install *.ttf $RPM_BUILD_ROOT%{ttffontsdir} | |
82 | %endif | |
83 | ||
84 | %clean | |
85 | rm -rf $RPM_BUILD_ROOT | |
86 | ||
87 | %if %{with license_agreement} | |
88 | %post | |
89 | fontpostinst TTF | |
90 | ||
91 | %postun | |
92 | fontpostinst TTF | |
93 | ||
94 | %else | |
fb8127d0 | 95 | %post |
f2dd53b0 | 96 | echo " |
97 | License issues made us not to include inherent files into this package | |
98 | by default (it probably requires Windows license). If you want to | |
99 | create full working package please build it with the following command: | |
100 | ||
101 | %{base_name}.install --with license_agreement %{_datadir}/%{base_name}/%{base_name}.spec | |
102 | " | |
103 | %endif | |
104 | ||
105 | %files | |
106 | %defattr(644,root,root,755) | |
107 | %if %{with license_agreement} | |
108 | %{ttffontsdir}/* | |
109 | %else | |
110 | %attr(755,root,root) %{_bindir}/%{base_name}.install | |
111 | %{_datadir}/%{base_name} | |
112 | %endif |