]> git.pld-linux.org Git - packages/fontconfig.git/blob - fontconfig.spec
up to 2.14.0
[packages/fontconfig.git] / fontconfig.spec
1 #
2 # Conditional build
3 %bcond_without  static_libs     # don't build static library
4 %bcond_without  doc             # don't build HTML and man docs
5 %bcond_without  tests           # don't perform make check
6
7 Summary:        Font configuration and customization tools
8 Summary(pl.UTF-8):      Narzędzia do konfigurowania fontów
9 Summary(pt_BR.UTF-8):   Ferramentas para configuração e customização do acesso a fontes
10 Name:           fontconfig
11 Version:        2.14.0
12 Release:        1
13 Epoch:          1
14 License:        MIT
15 Group:          Libraries
16 Source0:        https://www.freedesktop.org/software/fontconfig/release/%{name}-%{version}.tar.xz
17 # Source0-md5:  e12700a9d522bdfec06b6b7e72646987
18 Source1:        %{name}-lcd-filter.conf
19 Patch0:         %{name}-bitstream-cyberbit.patch
20 URL:            http://fontconfig.org/
21 BuildRequires:  autoconf >= 2.61
22 BuildRequires:  automake >= 1:1.11
23 %if %{with doc}
24 BuildRequires:  docbook-dtd31-sgml
25 BuildRequires:  docbook-dtd41-sgml
26 BuildRequires:  docbook-utils >= 0.6.13-3
27 %endif
28 BuildRequires:  ed
29 BuildRequires:  expat-devel
30 # pkgconfig(freetype) >= 21.0.15
31 BuildRequires:  freetype-devel >= 1:2.9
32 BuildRequires:  gettext-tools >= 0.19.8
33 BuildRequires:  gperf
34 %{?with_tests:BuildRequires:    json-c-devel}
35 BuildRequires:  libtool >= 2:2.2
36 BuildRequires:  libuuid-devel
37 BuildRequires:  pkgconfig
38 %{?with_doc:BuildRequires:      python3}
39 BuildRequires:  tar >= 1:1.22
40 BuildRequires:  xz
41 Requires:       %{name}-libs = %{epoch}:%{version}-%{release}
42 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
43
44 %description
45 Fontconfig is designed to locate fonts within the system and select
46 them according to requirements specified by applications.
47
48 This package contains tools and documentation.
49
50 %description -l pl.UTF-8
51 Fontconfig jest biblioteką przeznaczoną do lokalizowania fontów w
52 systemie i wybierania ich w zależności od potrzeb aplikacji.
53
54 Paket ten zawiera programy narzędziowe i dokumentację.
55
56 %description -l pt_BR.UTF-8
57 Fontconfig é uma biblioteca para configuração e customização do acesso
58 a fontes.
59
60 Este pacote contém as ferramentas e documentação.
61
62 %package libs
63 Summary:        Font configuration and customization library
64 Summary(pl.UTF-8):      Biblioteka do konfigurowania fontów
65 Summary(pt_BR.UTF-8):   Biblioteca para configuração e customização do acesso a fontes
66 Group:          Libraries
67 Requires:       freetype >= 1:2.9
68 Provides:       XFree86-fontconfig
69 Obsoletes:      XFree86-fontconfig
70 Conflicts:      fontconfig <= 1:2.2.98-1
71
72 %description libs
73 Fontconfig is designed to locate fonts within the system and select
74 them according to requirements specified by applications.
75
76 %description libs -l pl.UTF-8
77 Fontconfig jest biblioteką przeznaczoną do lokalizowania fontów w
78 systemie i wybierania ich w zależności od potrzeb aplikacji.
79
80 %description libs -l pt_BR.UTF-8
81 Fontconfig é uma biblioteca para configuração e customização do acesso
82 a fontes.
83
84 %package devel
85 Summary:        Font configuration and customization library - development files
86 Summary(pl.UTF-8):      Biblioteka do konfigurowania fontów - pliki dla programistów
87 Summary(pt_BR.UTF-8):   Biblioteca para configuração e customização do acesso a fontes - arquivos de desenvolvimento
88 Group:          Development/Libraries
89 Requires:       %{name}-libs = %{epoch}:%{version}-%{release}
90 Requires:       expat-devel
91 Requires:       freetype-devel >= 1:2.9
92 Requires:       libuuid-devel
93 Provides:       XFree86-fontconfig-devel
94 Obsoletes:      XFree86-fontconfig-devel
95
96 %description devel
97 Fontconfig is designed to locate fonts within the system and select
98 them according to requirements specified by applications.
99
100 This package contains the header files needed to develop programs that
101 use these fontconfig.
102
103 %description devel -l pl.UTF-8
104 Fontconfig jest biblioteką przeznaczoną do lokalizowania fontów w
105 systemie i wybierania ich w zależności od potrzeb aplikacji.
106
107 Ten pakiet zawiera pliki nagłówkowe potrzebne do kompilowania
108 programów korzystających z biblioteki fontconfig.
109
110 %description devel -l pt_BR.UTF-8
111 Fontconfig é uma biblioteca para configuração e customização do acesso
112 a fontes.
113
114 Este pacote contém arquivos de desenvolvimento necessários à criação
115 de extensões baseadas na biblioteca fontconfig.
116
117 %package static
118 Summary:        Static font configuration and customization library
119 Summary(pl.UTF-8):      Statyczna biblioteka do konfigurowania fontów
120 Summary(pt_BR.UTF-8):   Biblioteca estática para configuração e customização do acesso a fontes
121 Group:          Development/Libraries
122 Requires:       %{name}-devel = %{epoch}:%{version}-%{release}
123 Provides:       XFree86-fontconfig-static
124 Obsoletes:      XFree86-fontconfig-static
125
126 %description static
127 This package contains static version of fontconfig library.
128
129 %description static -l pl.UTF-8
130 Ten pakiet zawiera statyczną wersję biblioteki fontconfig.
131
132 %description static -l pt_BR.UTF-8
133 Este pacote contém a biblioteca estática do fontconfig
134
135 %prep
136 %setup -q
137 %patch0 -p1
138
139 # bwrap: No permissions to creating new namespace, likely because the kernel does not allow non-privileged user namespaces...
140 sed -i -e 's#BWRAP=.*#BWRAP=#g' test/run-test.sh
141
142 %build
143 %{__gettextize}
144 %{__libtoolize}
145 %{__aclocal} -I m4
146 %{__autoconf}
147 %{__autoheader}
148 %{__automake}
149
150 # don't rebuild docs by default, use prebuild ones
151 export HASDOCBOOK=no
152
153 %configure \
154         --enable-docs%{!?with_doc:=no} \
155         --disable-silent-rules \
156         --%{?with_static_libs:en}%{!?with_static_libs:dis}able-static
157 %{__make}
158
159 %{?with_tests:%{__make} OSTYPE=linux check || (cat test/test-suite.log && /bin/false)}
160
161 %install
162 rm -rf $RPM_BUILD_ROOT
163 install -d $RPM_BUILD_ROOT{%{_mandir}/man{1,3,5},/var/cache/fontconfig} \
164
165 %{__make} install \
166         DESTDIR=$RPM_BUILD_ROOT \
167         htmldoc_DATA= \
168         doc_DATA=
169
170 install %{SOURCE1} \
171         $RPM_BUILD_ROOT%{_datadir}/%{name}/conf.avail/10-lcd-filter.conf
172
173 ln -s %{_datadir}/%{name}/conf.avail $RPM_BUILD_ROOT%{_sysconfdir}/fonts/conf.avail
174
175 cp -pf conf.d/README README.confd
176
177 %find_lang %{name}
178 %find_lang %{name}-conf -a %{name}.lang
179
180 %clean
181 rm -rf $RPM_BUILD_ROOT
182
183 %pretrans
184 # this needs to be a symlink
185 if [ -d %{_sysconfdir}/fonts/conf.avail ] && [ ! -L %{_sysconfdir}/fonts/conf.avail ]; then
186         mv -f %{_sysconfdir}/fonts/conf.avail{,.rpmsave}
187         install -d %{_datadir}/%{name}/conf.avail
188         ln -s %{_datadir}/%{name}/conf.avail %{_sysconfdir}/fonts/conf.avail
189         mv -f %{_sysconfdir}/fonts/conf.avail.rpmsave/*.conf %{_sysconfdir}/fonts/conf.avail/
190         rmdir %{_sysconfdir}/fonts/conf.avail.rpmsave 2>/dev/null || :
191 fi
192
193 %post
194 umask 022
195 HOME=/tmp %{_bindir}/fc-cache -f 2>/dev/null || :
196
197 %post   libs -p /sbin/ldconfig
198 %postun libs -p /sbin/ldconfig
199
200 %files -f %{name}.lang
201 %defattr(644,root,root,755)
202 %doc AUTHORS COPYING ChangeLog README README.confd doc/fontconfig-user.html
203 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/fonts/fonts.conf
204 %{_sysconfdir}/fonts/conf.avail
205 %{_sysconfdir}/fonts/conf.d/README
206 %config(noreplace,missingok) %verify(not link md5 mtime size) %{_sysconfdir}/fonts/conf.d/*.conf
207 %attr(755,root,root) %{_bindir}/fc-cache
208 %attr(755,root,root) %{_bindir}/fc-cat
209 %attr(755,root,root) %{_bindir}/fc-conflist
210 %attr(755,root,root) %{_bindir}/fc-list
211 %attr(755,root,root) %{_bindir}/fc-match
212 %attr(755,root,root) %{_bindir}/fc-query
213 %attr(755,root,root) %{_bindir}/fc-pattern
214 %attr(755,root,root) %{_bindir}/fc-scan
215 %attr(755,root,root) %{_bindir}/fc-validate
216 %dir %{_datadir}/xml/%{name}
217 %{_datadir}/xml/%{name}/fonts.dtd
218 %{_datadir}/%{name}/conf.avail/*.conf
219 %if %{with doc}
220 %{_mandir}/man1/fc-*.1*
221 %{_mandir}/man5/fonts-conf.5*
222 %endif
223 %dir /var/cache/fontconfig
224
225 %files libs
226 %defattr(644,root,root,755)
227 %attr(755,root,root) %{_libdir}/libfontconfig.so.*.*.*
228 %attr(755,root,root) %ghost %{_libdir}/libfontconfig.so.1
229
230 %files devel
231 %defattr(644,root,root,755)
232 %doc doc/fontconfig-devel/*.html
233 %attr(755,root,root) %{_libdir}/libfontconfig.so
234 %{_libdir}/libfontconfig.la
235 %{_includedir}/fontconfig
236 %{_pkgconfigdir}/fontconfig.pc
237 %{_datadir}/gettext/its/fontconfig.its
238 %{_datadir}/gettext/its/fontconfig.loc
239 %if %{with doc}
240 %{_mandir}/man3/Fc*.3*
241 %endif
242
243 %if %{with static_libs}
244 %files static
245 %defattr(644,root,root,755)
246 %{_libdir}/libfontconfig.a
247 %endif
This page took 0.067826 seconds and 4 git commands to generate.