3 %bcond_with gtk3 # use GTK+ 3.x instead of 2.x
4 %bcond_without python # Python bindings (GTK+ 2.x only)
9 Summary: Library to allow MATE Desktop to display weather information
10 Summary(pl.UTF-8): Biblioteka umożliwiająca wyświetlanie informacji pogodowych w środowisku MATE Desktop
16 Source0: http://pub.mate-desktop.org/releases/1.12/%{name}-%{version}.tar.xz
17 # Source0-md5: 25064c09873f60e99fa971162c470e37
18 URL: http://wiki.mate-desktop.org/libmateweather
19 BuildRequires: autoconf >= 2.59
20 BuildRequires: automake >= 1:1.9
21 BuildRequires: gettext-tools
22 BuildRequires: glib2-devel >= 1:2.36.0
23 %{!?with_gtk3:BuildRequires: gtk+2-devel >= 2:2.24.0}
24 %{?with_gtk3:BuildRequires: gtk+3-devel >= 3.0.0}
25 BuildRequires: gtk-doc >= 1.11
26 BuildRequires: intltool >= 0.50.1
27 BuildRequires: libsoup-devel >= 2.34.0
28 BuildRequires: libtool >= 2:2.2.6
29 BuildRequires: libxml2-devel >= 1:2.6.0
30 BuildRequires: mate-common
31 BuildRequires: pkgconfig >= 1:0.19
33 BuildRequires: python-devel >= 2
34 BuildRequires: python-pygobject-devel >= 2.0
35 BuildRequires: python-pygtk-devel >= 2:2.0
37 BuildRequires: rpm-pythonprov
38 BuildRequires: rpmbuild(macros) >= 1.219
39 BuildRequires: tar >= 1:1.22
41 Requires(post,postun): /sbin/ldconfig
42 Requires: glib2 >= 1:2.36.0
43 Requires: gsettings-desktop-schemas
44 %{!?with_gtk3:Requires: gtk+2 >= 2:2.24.0}
45 %{?with_gtk3:Requires: gtk+3 >= 3.0.0}
46 Requires: gtk-update-icon-cache
47 Requires: libxml2 >= 1:2.6.0
48 Requires: mate-icon-theme
49 Conflicts: mate-applet-gweather < 1.6.1
50 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
53 libmateweather is a library to allow MATE Desktop to display weather
54 information. It's a fork of libgweather.
56 %description -l pl.UTF-8
57 libmateweather to biblioteka umożliwiająca wyświetlanie informacji
58 pogodowych w środowisku MATE Desktop. Jest odgałęzieniem libgweather.
61 Summary: Development files for libmateweather
62 Summary(pl.UTF-8): Pliki programistyczne biblioteki libmateweather
63 Group: X11/Development/Libraries
64 Requires: %{name} = %{version}-%{release}
65 Requires: glib2-devel >= 1:2.36.0
66 %{!?with_gtk3:Requires: gtk+2-devel >= 2:2.24.0}
67 %{?with_gtk3:Requires: gtk+3-devel >= 3.0.0}
68 Requires: libsoup-devel >= 2.4.0
69 Requires: libxml2-devel >= 1:2.6.0
72 Development files for libmateweather.
74 %description devel -l pl.UTF-8
75 Pliki programistyczne biblioteki libmateweather.
78 Summary: libmateweather API documentation
79 Summary(pl.UTF-8): Dokumentacja API biblioteki libmateweather
81 Requires: gtk-doc-common
82 %if "%{_rpmversion}" >= "5"
87 libmateweather API documentation.
89 %description apidocs -l pl.UTF-8
90 Dokumentacja API biblioteki libmateweather.
92 %package -n python-mateweather
93 Summary: Python binding for libmateweather library
94 Summary(pl.UTF-8): Wiązanie Pythona do biblioteki libmateweather
95 Group: Libraries/Python
96 Requires: %{name} = %{version}-%{release}
97 Requires: python-pygobject >= 2.0
98 Requires: python-pygtk-gtk >= 2:2.0
100 %description -n python-mateweather
101 Python binding for libmateweather library.
103 %description -n python-mateweather -l pl.UTF-8
104 Wiązanie Pythona do biblioteki libmateweather.
116 %{?with_gtk3:--with-gtk=3.0} \
117 --with-html-dir=%{_gtkdocdir} \
118 --with-zoneinfo-dir=%{_datadir}/zoneinfo \
119 %{?with_python:--enable-python} \
120 --disable-silent-rules \
126 rm -rf $RPM_BUILD_ROOT
128 DESTDIR=$RPM_BUILD_ROOT
130 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libmateweather.la
131 %{__rm} $RPM_BUILD_ROOT%{py_sitedir}/mateweather/*/mateweather.la
134 %py_ocomp $RPM_BUILD_ROOT%{py_sitedir}
135 %py_comp $RPM_BUILD_ROOT%{py_sitedir}
139 # outdated copy of es
140 %{__rm} -r $RPM_BUILD_ROOT%{_localedir}/es_ES
145 rm -rf $RPM_BUILD_ROOT
149 %update_icon_cache mate
150 %glib_compile_schemas
154 %update_icon_cache mate
155 %glib_compile_schemas
157 %files -f %{name}.lang
158 %defattr(644,root,root,755)
159 %doc AUTHORS ChangeLog NEWS README
160 %attr(755,root,root) %{_libdir}/libmateweather.so.*.*.*
161 %attr(755,root,root) %ghost %{_libdir}/libmateweather.so.1
162 %{_datadir}/libmateweather
163 %{_datadir}/glib-2.0/schemas/org.mate.weather.gschema.xml
164 %{_iconsdir}/mate/*x*/status/weather-*.png
165 %{_iconsdir}/mate/scalable/status/weather-*.svg
168 %defattr(644,root,root,755)
169 %attr(755,root,root) %{_libdir}/libmateweather.so
170 %{_includedir}/libmateweather
171 %{_pkgconfigdir}/mateweather.pc
174 %defattr(644,root,root,755)
175 %{_gtkdocdir}/libmateweather
178 %files -n python-mateweather
179 %defattr(644,root,root,755)
180 %dir %{py_sitedir}/mateweather
181 %{py_sitedir}/mateweather/*.py[co]
182 %dir %{py_sitedir}/mateweather/I_KNOW_THIS_IS_UNSTABLE
183 %{py_sitedir}/mateweather/I_KNOW_THIS_IS_UNSTABLE/*.py[co]
184 %attr(755,root,root) %{py_sitedir}/mateweather/I_KNOW_THIS_IS_UNSTABLE/mateweather.so