]>
Commit | Line | Data |
---|---|---|
24e54331 JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without static_libs # static library | |
4 | ||
beb976bc | 5 | Summary: XPS documents library |
734e7a2c | 6 | Summary(pl.UTF-8): Biblioteka do obsługi dokumentów XPS |
beb976bc | 7 | Name: libgxps |
9954a519 | 8 | Version: 0.3.2 |
b75a967d | 9 | Release: 2 |
769cbe18 | 10 | License: LGPL v2.1+ |
beb976bc | 11 | Group: Libraries |
9954a519 JB |
12 | Source0: https://download.gnome.org/sources/libgxps/0.3/%{name}-%{version}.tar.xz |
13 | # Source0-md5: 0527ac7c8c405445e96a5baa6019a0c3 | |
24e54331 | 14 | URL: https://wiki.gnome.org/Projects/libgxps |
beb976bc | 15 | BuildRequires: cairo-devel >= 1.10.0 |
dec9da79 | 16 | BuildRequires: freetype-devel >= 2 |
24e54331 | 17 | BuildRequires: glib2-devel >= 1:2.36.0 |
beb976bc MB |
18 | BuildRequires: gobject-introspection-devel >= 0.10.1 |
19 | BuildRequires: gtk-doc >= 1.14 | |
dec9da79 | 20 | BuildRequires: lcms2-devel >= 2 |
beb976bc MB |
21 | BuildRequires: libarchive-devel >= 2.8.0 |
22 | BuildRequires: libjpeg-devel | |
3c5fb40d | 23 | BuildRequires: libpng-devel |
24e54331 | 24 | BuildRequires: libtiff-devel >= 4 |
734e7a2c | 25 | BuildRequires: libxslt-progs |
24e54331 | 26 | BuildRequires: meson >= 0.36.0 |
9954a519 | 27 | BuildRequires: ninja >= 1.5 |
beb976bc | 28 | BuildRequires: pkgconfig |
9954a519 | 29 | BuildRequires: rpmbuild(macros) >= 1.752 |
24e54331 | 30 | BuildRequires: sed >= 4.0 |
beb976bc MB |
31 | BuildRequires: tar >= 1:1.22 |
32 | BuildRequires: xz | |
734e7a2c | 33 | Requires: cairo >= 1.10.0 |
24e54331 | 34 | Requires: glib2 >= 1:2.36.0 |
734e7a2c | 35 | Requires: libarchive >= 2.8.0 |
24e54331 | 36 | Requires: libtiff >= 4 |
beb976bc MB |
37 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
38 | ||
39 | %description | |
40 | libgxps is a GObject based library for handling and rendering XPS | |
41 | documents. | |
42 | ||
734e7a2c JB |
43 | %description -l pl.UTF-8 |
44 | libgxps to oparta na szkielecie GObject biblioteka do obsługi i | |
45 | renderowania dokumentów XPS. | |
46 | ||
beb976bc MB |
47 | %package devel |
48 | Summary: Header files for libgxps library | |
49 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libgxps | |
50 | Group: Development/Libraries | |
51 | Requires: %{name} = %{version}-%{release} | |
52 | Requires: cairo-devel >= 1.10.0 | |
24e54331 | 53 | Requires: glib2-devel >= 1:2.36.0 |
beb976bc MB |
54 | Requires: libarchive-devel >= 2.8.0 |
55 | ||
56 | %description devel | |
57 | Header files for libgxps library. | |
58 | ||
59 | %description devel -l pl.UTF-8 | |
60 | Pliki nagłówkowe biblioteki libgxps. | |
61 | ||
734e7a2c JB |
62 | %package static |
63 | Summary: Static libgxps libary | |
64 | Summary(pl.UTF-8): Statyczna biblioteka libgxps | |
65 | Group: Development/Libraries | |
66 | Requires: %{name}-devel = %{version}-%{release} | |
67 | ||
68 | %description static | |
69 | Static libgxps libary. | |
70 | ||
71 | %description static -l pl.UTF-8 | |
72 | Statyczna biblioteka libgxps. | |
73 | ||
beb976bc MB |
74 | %package apidocs |
75 | Summary: libgxps API documentation | |
76 | Summary(pl.UTF-8): Dokumentacja API biblioteki libgxps | |
77 | Group: Documentation | |
78 | Requires: gtk-doc-common | |
4c82cb38 | 79 | BuildArch: noarch |
beb976bc MB |
80 | |
81 | %description apidocs | |
82 | API documentation for libgxps library. | |
83 | ||
84 | %description apidocs -l pl.UTF-8 | |
85 | Dokumentacja API biblioteki libgxps. | |
86 | ||
87 | %prep | |
88 | %setup -q | |
89 | ||
24e54331 JB |
90 | %if %{with static_libs} |
91 | %{__sed} -i -e 's/shared_library/library/' libgxps/meson.build | |
92 | %endif | |
93 | ||
beb976bc | 94 | %build |
24e54331 JB |
95 | %meson build \ |
96 | -Denable-gtk-doc=true \ | |
97 | -Denable-man=true | |
98 | ||
99 | %meson_build -C build | |
beb976bc MB |
100 | |
101 | %install | |
102 | rm -rf $RPM_BUILD_ROOT | |
103 | ||
24e54331 | 104 | %meson_install -C build |
beb976bc MB |
105 | |
106 | %clean | |
107 | rm -rf $RPM_BUILD_ROOT | |
108 | ||
109 | %post -p /sbin/ldconfig | |
110 | %postun -p /sbin/ldconfig | |
111 | ||
112 | %files | |
113 | %defattr(644,root,root,755) | |
24e54331 | 114 | %doc AUTHORS MAINTAINERS NEWS README TODO |
3c5fb40d MB |
115 | %attr(755,root,root) %{_bindir}/xpstojpeg |
116 | %attr(755,root,root) %{_bindir}/xpstopdf | |
117 | %attr(755,root,root) %{_bindir}/xpstopng | |
118 | %attr(755,root,root) %{_bindir}/xpstops | |
119 | %attr(755,root,root) %{_bindir}/xpstosvg | |
beb976bc | 120 | %attr(755,root,root) %{_libdir}/libgxps.so.*.*.* |
3c5fb40d | 121 | %attr(755,root,root) %ghost %{_libdir}/libgxps.so.2 |
beb976bc | 122 | %{_libdir}/girepository-1.0/GXPS-0.1.typelib |
24e54331 JB |
123 | %{_mandir}/man1/xpstojpeg.1* |
124 | %{_mandir}/man1/xpstopdf.1* | |
125 | %{_mandir}/man1/xpstopng.1* | |
126 | %{_mandir}/man1/xpstops.1* | |
127 | %{_mandir}/man1/xpstosvg.1* | |
beb976bc MB |
128 | |
129 | %files devel | |
130 | %defattr(644,root,root,755) | |
131 | %attr(755,root,root) %{_libdir}/libgxps.so | |
132 | %{_datadir}/gir-1.0/GXPS-0.1.gir | |
133 | %{_includedir}/libgxps | |
134 | %{_pkgconfigdir}/libgxps.pc | |
135 | ||
24e54331 | 136 | %if %{with static_libs} |
734e7a2c JB |
137 | %files static |
138 | %defattr(644,root,root,755) | |
139 | %{_libdir}/libgxps.a | |
24e54331 | 140 | %endif |
734e7a2c | 141 | |
beb976bc MB |
142 | %files apidocs |
143 | %defattr(644,root,root,755) | |
144 | %{_gtkdocdir}/libgxps |