]>
Commit | Line | Data |
---|---|---|
d11eeff6 JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without apidocs # API documentation | |
4 | %bcond_without static_libs # static library | |
5 | ||
52cf347b | 6 | Summary: template-glib - generate text based on a template and user defined state |
d11eeff6 | 7 | Summary(pl.UTF-8): template-glib - generowanie tekstu w oparciu o szablon i stan przekazany przez użytkownika |
52cf347b | 8 | Name: template-glib |
61abcdf1 | 9 | Version: 3.36.2 |
d11eeff6 | 10 | Release: 1 |
52cf347b JR |
11 | License: LGPL v2.1+ |
12 | Group: Libraries | |
25ca2be0 | 13 | Source0: https://download.gnome.org/sources/template-glib/3.36/%{name}-%{version}.tar.xz |
61abcdf1 | 14 | # Source0-md5: e48ec153f5a7ead3ab53b62bc378bb57 |
d11eeff6 JB |
15 | URL: https://gitlab.gnome.org/GNOME/template-glib |
16 | BuildRequires: bison | |
52cf347b JR |
17 | BuildRequires: docbook-dtd412-xml |
18 | BuildRequires: gettext-tools >= 0.18 | |
d11eeff6 | 19 | BuildRequires: flex |
52cf347b JR |
20 | BuildRequires: glib2-devel >= 1:2.44.0 |
21 | BuildRequires: gobject-introspection-devel >= 0.9.5 | |
d11eeff6 | 22 | %{?with_apidocs:BuildRequires: gtk-doc >= 1.20} |
25ca2be0 | 23 | BuildRequires: meson >= 0.51.0 |
d11eeff6 | 24 | BuildRequires: ninja >= 1.5 |
52cf347b | 25 | BuildRequires: pkgconfig |
2ac8f124 | 26 | BuildRequires: rpm-build >= 4.6 |
d11eeff6 | 27 | BuildRequires: rpmbuild(macros) >= 1.736 |
52cf347b JR |
28 | BuildRequires: vala |
29 | Requires: glib2 >= 1:2.44.0 | |
30 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
31 | ||
32 | %description | |
33 | Template-GLib is a library to help you generate text based on a | |
34 | template and user defined state. Template-GLib does not use a language | |
35 | runtime, so it is safe to use from any GObject-Introspectable | |
36 | language. | |
37 | ||
38 | Template-GLib allows you to access properties on GObjects as well as | |
d11eeff6 JB |
39 | call simple methods via GObject-Introspection. |
40 | ||
41 | %description -l pl.UTF-8 | |
42 | Template-GLib to biblioteka pomagająca generować tekst w oparciu o | |
43 | szablon oraz stan przekazany przez użytkownika. Nie wykorzystuje | |
44 | bibliotek językowych, więc bezpiecznie można jej używać z dowolnego | |
45 | języka obsługującego GObject-Introspection. | |
46 | ||
47 | Template-GLib pozwala na dostęp do właściwości obiektów GObject, a | |
48 | także wywoływanie prostych metod poprzez GObject-Introspection. | |
52cf347b JR |
49 | |
50 | %package devel | |
51 | Summary: Header files for the template-glib library | |
52 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki template-glib | |
53 | Group: Development/Libraries | |
54 | Requires: %{name} = %{version}-%{release} | |
55 | Requires: glib2-devel >= 1:2.44.0 | |
d11eeff6 | 56 | Requires: gobject-introspection-devel >= 0.9.5 |
52cf347b JR |
57 | |
58 | %description devel | |
59 | Header files for the template-glib library. | |
60 | ||
61 | %description devel -l pl.UTF-8 | |
62 | Pliki nagłówkowe biblioteki template-glib. | |
63 | ||
d11eeff6 JB |
64 | %package static |
65 | Summary: Static template-glib library | |
66 | Summary(pl.UTF-8): Biblioteka statyczna template-glib | |
67 | Group: Development/Libraries | |
68 | Requires: %{name}-devel = %{version}-%{release} | |
69 | ||
70 | %description static | |
71 | Static template-glib library. | |
72 | ||
73 | %description static -l pl.UTF-8 | |
74 | Biblioteka statyczna template-glib. | |
75 | ||
52cf347b JR |
76 | %package apidocs |
77 | Summary: template-glib API documentation | |
78 | Summary(pl.UTF-8): Dokumentacja API template-glib | |
79 | Group: Documentation | |
80 | Requires: gtk-doc-common | |
52cf347b | 81 | BuildArch: noarch |
52cf347b JR |
82 | |
83 | %description apidocs | |
84 | Template-glib API documentation. | |
85 | ||
86 | %description apidocs -l pl.UTF-8 | |
87 | Dokumentacja API template-glib. | |
88 | ||
89 | %package -n vala-template-glib | |
90 | Summary: template-glib API for Vala language | |
91 | Summary(pl.UTF-8): API template-glib dla języka Vala | |
92 | Group: Development/Libraries | |
93 | Requires: %{name}-devel = %{version}-%{release} | |
94 | Requires: vala >= 2:0.18.0 | |
52cf347b | 95 | BuildArch: noarch |
52cf347b JR |
96 | |
97 | %description -n vala-template-glib | |
98 | Template-glib API for Vala language. | |
99 | ||
100 | %description -n vala-template-glib -l pl.UTF-8 | |
101 | API template-glib dla języka Vala. | |
102 | ||
103 | %prep | |
104 | %setup -q | |
105 | ||
106 | %build | |
107 | %meson build \ | |
d11eeff6 | 108 | %{!?with_static_libs:--default-library=shared} \ |
25ca2be0 | 109 | %{?with_apidocs:-Dgtk_doc=true} |
52cf347b | 110 | |
d11eeff6 | 111 | %ninja_build -C build |
52cf347b JR |
112 | |
113 | %install | |
114 | rm -rf $RPM_BUILD_ROOT | |
115 | ||
d11eeff6 | 116 | %ninja_install -C build |
52cf347b JR |
117 | |
118 | %find_lang %{name} --with-gnome | |
119 | ||
120 | %clean | |
121 | rm -rf $RPM_BUILD_ROOT | |
122 | ||
123 | %post -p /sbin/ldconfig | |
124 | %postun -p /sbin/ldconfig | |
125 | ||
126 | %files -f %{name}.lang | |
127 | %defattr(644,root,root,755) | |
d11eeff6 | 128 | %doc AUTHORS NEWS README.md |
52cf347b JR |
129 | %attr(755,root,root) %{_libdir}/libtemplate_glib-1.0.so.*.*.* |
130 | %attr(755,root,root) %ghost %{_libdir}/libtemplate_glib-1.0.so.0 | |
131 | %{_libdir}/girepository-1.0/Template-1.0.typelib | |
132 | ||
133 | %files devel | |
134 | %defattr(644,root,root,755) | |
135 | %attr(755,root,root) %{_libdir}/libtemplate_glib-1.0.so | |
136 | %{_datadir}/gir-1.0/Template-1.0.gir | |
137 | %{_includedir}/template-glib-1.0 | |
138 | %{_pkgconfigdir}/template-glib-1.0.pc | |
139 | ||
d11eeff6 JB |
140 | %if %{with static_libs} |
141 | %files static | |
142 | %defattr(644,root,root,755) | |
143 | %{_libdir}/libtemplate_glib-1.0.a | |
144 | %endif | |
145 | ||
146 | %if %{with apidocs} | |
52cf347b JR |
147 | %files apidocs |
148 | %defattr(644,root,root,755) | |
149 | %{_gtkdocdir}/template-glib | |
d11eeff6 | 150 | %endif |
52cf347b JR |
151 | |
152 | %files -n vala-template-glib | |
153 | %defattr(644,root,root,755) | |
154 | %{_datadir}/vala/vapi/template-glib-1.0.deps | |
155 | %{_datadir}/vala/vapi/template-glib-1.0.vapi |