#
+# TODO: fix build with lua. Now when lua enabled conky requires tolua++-devel when installing
+#
# Conditional build:
-%bcond_without lua_cairo # without lua cairo bindings
+%bcond_with lua_cairo # without lua cairo bindings
+%bcond_with lua_imlib2 # without lua imlib2 bindings
#
Summary: A light-weight system monitor
Summary(pl.UTF-8): Monitor systemu dla środowiska graficznego
Name: conky
Version: 1.8.1
-Release: 3
+Release: 5
License: Distributable (see COPYING doc)
Group: X11/Applications
Source0: http://downloads.sourceforge.net/conky/%{name}-%{version}.tar.bz2
BuildRequires: curl-devel
BuildRequires: expat-devel
BuildRequires: freetype-devel
-BuildRequires: gettext-devel
+BuildRequires: gettext-tools
BuildRequires: glib2-devel >= 2.0
BuildRequires: imlib2-devel
BuildRequires: libtool
+BuildRequires: libxml2-devel
BuildRequires: lua51-devel >= 5.1
BuildRequires: ncurses-devel
BuildRequires: pkgconfig >= 1:0.19
BuildRequires: sed >= 4.0
-%{?with_lua_cairo:BuildRequires: tolua++-devel >= 1.0.90}
+BuildRequires: sqlite3-devel
+%if %{with lua_cairo} || %{with lua_imlib2}
+BuildRequires: tolua++-devel >= 1.0.90
+%endif
BuildRequires: xorg-lib-libXdamage-devel
BuildRequires: xorg-lib-libXext-devel
BuildRequires: xorg-lib-libXft-devel
%{__automake}
%configure \
CFLAGS="%{rpmcflags} `pkg-config ncurses --cflags`" \
- LIBS="-ltinfo" \
--enable-curl \
--enable-imlib2 \
+ --enable-weather-xoap \
+ --enable-wlan \
+ --enable-rss \
%{?with_lua_cairo:--enable-lua-cairo} \
- --enable-lua-imlib2
+ %{?with_lua_imlib2:--enable-lua-imlib2}
%{__make}
%dir %{_sysconfdir}/conky
%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conky/%{name}.conf
%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conky/%{name}_no_x11.conf
+%if %{with lua_cairo} || %{with lua_imlib2}
%dir %{_libdir}/conky
+%endif
%{_mandir}/man1/%{name}.1*
%if %{with lua_cairo}
%{_libdir}/conky/libcairo.so
%endif
+%if %{with lua_imlib2}
%files lua-imlib2
%defattr(644,root,root,755)
%attr(755,root,root) %{_libdir}/conky/libimlib2.so.*.*.*
%{_libdir}/conky/libimlib2.so
+%endif