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