]> git.pld-linux.org Git - packages/appstream-glib.git/blob - appstream-glib.spec
a877900aaeb45657c0f7e51a83cad14a14a77bd8
[packages/appstream-glib.git] / appstream-glib.spec
1 #
2 # Conditional build:
3 %bcond_with     alpm            # Arch Linux PacMan support
4 %bcond_with     stemmer         # search stemmer based on libstemmer
5 %bcond_without  static_libs     # static libraries
6
7 Summary:        GLib Objects and helper methods for reading and writing AppStream metadata
8 Summary(pl.UTF-8):      Obiekty GLiba i metody pomocnicze do odczytu i zapisu metadanych AppStream
9 Name:           appstream-glib
10 Version:        0.7.14
11 Release:        1
12 License:        LGPL v2.1+
13 Group:          Libraries
14 Source0:        https://people.freedesktop.org/~hughsient/appstream-glib/releases/%{name}-%{version}.tar.xz
15 # Source0-md5:  48811c1105ce8b37ac274c6bf101075b
16 Patch0:         %{name}-rpm5.patch
17 Patch1:         %{name}-stemmer.patch
18 Patch2:         %{name}-pc.patch
19 URL:            https://people.freedesktop.org/~hughsient/appstream-glib/
20 %{?with_alpm:BuildRequires:     alpm-devel}
21 BuildRequires:  docbook-dtd43-xml
22 BuildRequires:  docbook-style-xsl
23 BuildRequires:  fontconfig-devel
24 # pkgconfig(freetype2) >= 9.10.0
25 BuildRequires:  freetype-devel >= 1:2.2.1
26 BuildRequires:  gcab-devel >= 1.0
27 BuildRequires:  gcc >= 5:3.2
28 BuildRequires:  gdk-pixbuf2-devel >= 2.31.5
29 BuildRequires:  gettext-tools >= 0.19.7
30 BuildRequires:  glib2-devel >= 1:2.45.8
31 BuildRequires:  gobject-introspection-devel >= 0.9.8
32 BuildRequires:  gperf
33 BuildRequires:  gtk+3-devel >= 3.0
34 BuildRequires:  gtk-doc >= 1.9
35 BuildRequires:  intltool >= 0.40.0
36 BuildRequires:  json-glib-devel >= 1.1.2
37 BuildRequires:  libarchive-devel
38 BuildRequires:  libsoup-devel >= 2.52
39 BuildRequires:  libstdc++-devel
40 %{?with_stemmer:BuildRequires:  libstemmer-devel}
41 BuildRequires:  libuuid-devel
42 BuildRequires:  libxslt-progs
43 BuildRequires:  meson >= 0.37.0
44 BuildRequires:  pango-devel
45 BuildRequires:  pkgconfig
46 BuildRequires:  rpm-devel >= 4.5
47 BuildRequires:  sqlite3-devel >= 3
48 BuildRequires:  tar >= 1:1.22
49 BuildRequires:  xz
50 BuildRequires:  yaml-devel >= 0.1
51 Requires:       gdk-pixbuf2 >= 2.31.5
52 Requires:       glib2 >= 1:2.45.8
53 Requires:       json-glib >= 1.1.2
54 Requires:       libsoup >= 2.52
55 Provides:       appdata-tools = %{version}
56 Obsoletes:      appdata-tools < 0.2
57 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
58
59 %description
60 AppStream-Glib library provides GObjects and helper methods to make it
61 easy to read and write AppStream metadata. It also provides a simple
62 DOM implementation that makes it easy to edit nodes and convert to and
63 from the standardized XML representation.
64
65 %description -l pl.UTF-8
66 Biblioteka AppStream-Glib dostarcza obiekty GLiba (GObject) oraz
67 metody pomocnicze ułatwiające odczyt i zapis metadanych AppStream.
68 Zapewnia także prostą implementację DOM ułatwiającą modyfikowanie
69 węzłów i konwersję do i ze standardowej reprezentacji XML.
70
71 %package devel
72 Summary:        Header files for appstream-glib library
73 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki appstream-glib
74 Group:          Development/Libraries
75 Requires:       %{name} = %{version}-%{release}
76 Requires:       gcab-devel >= 1.0
77 Requires:       gdk-pixbuf2-devel >= 2.31.5
78 Requires:       glib2-devel >= 1:2.45.8
79 Requires:       libarchive-devel
80 Requires:       libuuid-devel
81
82 %description devel
83 Header files for appstream-glib library.
84
85 %description devel -l pl.UTF-8
86 Pliki nagłówkowe biblioteki appstream-glib.
87
88 %package static
89 Summary:        Static appstream-glib library
90 Summary(pl.UTF-8):      Statyczna biblioteka appstream-glib
91 Group:          Development/Libraries
92 Requires:       %{name}-devel = %{version}-%{release}
93
94 %description static
95 Static appstream-glib library.
96
97 %description static -l pl.UTF-8
98 Statyczna biblioteka appstream-glib.
99
100 %package apidocs
101 Summary:        appstream-glib API documentation
102 Summary(pl.UTF-8):      Dokumentacja API biblioteki appstream-glib
103 Group:          Documentation
104 %if "%{_rpmversion}" >= "5"
105 BuildArch:      noarch
106 %endif
107
108 %description apidocs
109 API documentation for appstream-glib library.
110
111 %description apidocs -l pl.UTF-8
112 Dokumentacja API biblioteki appstream-glib.
113
114 %package -n bash-completion-appstream-glib
115 Summary:        Bash completion for appstream-glib package
116 Summary(pl.UTF-8):      Bashowe dopełnianie składni dla pakietu appstream-glib
117 Group:          Applications/Shells
118 Requires:       %{name} = %{version}-%{release}
119 Requires:       bash-completion >= 2.0
120
121 %description -n bash-completion-appstream-glib
122 Bash completion for appstream-util command.
123
124 %description -n bash-completion-appstream-glib -l pl.UTF-8
125 Bashowe dopełnianie składni polecenia appstream-util.
126
127 %package -n appstream-builder
128 Summary:        AppStreamBuilder library to create AppStream metadata from packages
129 Summary(pl.UTF-8):      Biblioteka AppStreamBuilder tworząca metadane AppStream z pakietów
130 Group:          Libraries
131 Requires:       %{name} = %{version}-%{release}
132 Requires:       freetype >= 1:2.2.1
133
134 %description -n appstream-builder
135 AppStreamBuilder library to create AppStream metadata from packages.
136
137 %description -n appstream-builder -l pl.UTF-8
138 Biblioteka AppStreamBuilder tworząca metadane AppStream z pakietów.
139
140 %package -n appstream-builder-devel
141 Summary:        Header files for AppStreamBuilder library
142 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki AppStreamBuilder
143 Group:          Development/Libraries
144 Requires:       %{name}-devel = %{version}-%{release}
145 Requires:       appstream-builder = %{version}-%{release}
146
147 %description -n appstream-builder-devel
148 Header files for AppStreamBuilder library.
149
150 %description -n appstream-builder-devel -l pl.UTF-8
151 Pliki nagłówkowe biblioteki AppStreamBuilder.
152
153 %package -n appstream-builder-static
154 Summary:        Static AppStreamBuilder library
155 Summary(pl.UTF-8):      Statyczna biblioteka AppStreamBuilder
156 Group:          Development/Libraries
157 Requires:       appstream-builder-devel = %{version}-%{release}
158
159 %description -n appstream-builder-static
160 Static AppStreamBuilder library.
161
162 %description -n appstream-builder-static -l pl.UTF-8
163 Statyczna biblioteka AppStreamBuilder.
164
165 %package -n bash-completion-appstream-builder
166 Summary:        Bash completion for appstream-builder package
167 Summary(pl.UTF-8):      Bashowe dopełnianie składni dla pakietu appstream-builder
168 Group:          Applications/Shells
169 Requires:       appstream-builder = %{version}-%{release}
170 Requires:       bash-completion >= 2.0
171
172 %description -n bash-completion-appstream-builder
173 Bash completion for appstream-builder command.
174
175 %description -n bash-completion-appstream-builder -l pl.UTF-8
176 Bashowe dopełnianie składni polecenia appstream-builder.
177
178 %prep
179 %setup -q
180 %patch0 -p1
181 %patch1 -p1
182 %patch2 -p1
183
184 %if %{with static_libs}
185 %{__sed} -i -e 's/shared_library/library/' libappstream-{builder,glib}/meson.build
186 %endif
187
188 %build
189 # for off64_t
190 CPPFLAGS="%{rpmcppflags} -D_LARGEFILE64_SOURCE"
191 %meson build \
192         -Dalpm=%{__true_false aplm} \
193         -Dstemmer=%{__true_false stemmer} \
194         -Dgtk-doc=true
195
196 %meson_build -C build
197
198 %install
199 rm -rf $RPM_BUILD_ROOT
200
201 %meson_install -C build
202
203 # already in gettext-tools >= 0.19.7
204 %{__rm} $RPM_BUILD_ROOT%{_datadir}/gettext/its/appdata.{its,loc}
205
206 %find_lang %{name}
207
208 %clean
209 rm -rf $RPM_BUILD_ROOT
210
211 %post   -p /sbin/ldconfig
212 %postun -p /sbin/ldconfig
213
214 %post   -n appstream-builder -p /sbin/ldconfig
215 %postun -n appstream-builder -p /sbin/ldconfig
216
217 %files -f %{name}.lang
218 %defattr(644,root,root,755)
219 %doc AUTHORS MAINTAINERS NEWS README.md
220 %attr(755,root,root) %{_bindir}/appstream-compose
221 %attr(755,root,root) %{_bindir}/appstream-util
222 %attr(755,root,root) %{_libdir}/libappstream-glib.so.*.*.*
223 %attr(755,root,root) %ghost %{_libdir}/libappstream-glib.so.8
224 %{_libdir}/girepository-1.0/AppStreamGlib-1.0.typelib
225 %{_aclocaldir}/appdata-xml.m4
226 %{_mandir}/man1/appstream-compose.1*
227 %{_mandir}/man1/appstream-util.1*
228
229 %files devel
230 %defattr(644,root,root,755)
231 %attr(755,root,root) %{_libdir}/libappstream-glib.so
232 %{_datadir}/gir-1.0/AppStreamGlib-1.0.gir
233 %{_includedir}/libappstream-glib
234 %{_pkgconfigdir}/appstream-glib.pc
235 %{_aclocaldir}/appstream-xml.m4
236
237 %if %{with static_libs}
238 %files static
239 %defattr(644,root,root,755)
240 %{_libdir}/libappstream-glib.a
241 %endif
242
243 %files -n bash-completion-appstream-glib
244 %defattr(644,root,root,755)
245 %{bash_compdir}/appstream-util
246
247 %files apidocs
248 %defattr(644,root,root,755)
249 %{_gtkdocdir}/appstream-glib
250
251 %files -n appstream-builder
252 %defattr(644,root,root,755)
253 %attr(755,root,root) %{_bindir}/appstream-builder
254 %attr(755,root,root) %{_libdir}/libappstream-builder.so.*.*.*
255 %attr(755,root,root) %ghost %{_libdir}/libappstream-builder.so.8
256 %{_libdir}/girepository-1.0/AppStreamBuilder-1.0.typelib
257 %dir %{_libdir}/asb-plugins-5
258 %attr(755,root,root) %{_libdir}/asb-plugins-5/libasb_plugin_appdata.so
259 %attr(755,root,root) %{_libdir}/asb-plugins-5/libasb_plugin_desktop.so
260 %attr(755,root,root) %{_libdir}/asb-plugins-5/libasb_plugin_font.so
261 %attr(755,root,root) %{_libdir}/asb-plugins-5/libasb_plugin_gettext.so
262 %attr(755,root,root) %{_libdir}/asb-plugins-5/libasb_plugin_hardcoded.so
263 %attr(755,root,root) %{_libdir}/asb-plugins-5/libasb_plugin_icon.so
264 %attr(755,root,root) %{_libdir}/asb-plugins-5/libasb_plugin_shell_extension.so
265 %{_mandir}/man1/appstream-builder.1*
266
267 %files -n appstream-builder-devel
268 %defattr(644,root,root,755)
269 %attr(755,root,root) %{_libdir}/libappstream-builder.so
270 %{_includedir}/libappstream-builder
271 %{_datadir}/gir-1.0/AppStreamBuilder-1.0.gir
272 %{_pkgconfigdir}/appstream-builder.pc
273
274 %if %{with static_libs}
275 %files -n appstream-builder-static
276 %defattr(644,root,root,755)
277 %{_libdir}/libappstream-builder.a
278 %endif
279
280 %files -n bash-completion-appstream-builder
281 %defattr(644,root,root,755)
282 %{bash_compdir}/appstream-builder
This page took 0.09374 seconds and 3 git commands to generate.