-# TODO:
-# - warning: Installed (but unpackaged) file(s) found:
-# /usr/lib/perl5/5.10.0/i686-pld-linux-thread-multi/perllocal.pod
-# /usr/lib/perl5/vendor_perl/5.10.0/i686-pld-linux-thread-multi/auto/Ekg2/.packlist
-# /usr/lib/perl5/vendor_perl/5.10.0/i686-pld-linux-thread-multi/auto/Ekg2/Irc/.packlist
#
# Conditional build:
%bcond_without aspell # build without spell-checking support with aspell
%bcond_without sqlite3 # don't build logsqlite plugin based on sqlite3
%bcond_with xosd # don't build xosd plugin
%bcond_with git # checkout git master instead of Source0 - requested by ekg2 developer
+%bcond_with irckeepalive # adds patch that check irc connection and disconnect when server dies
%if %{with git}
%define subver git.%(date +%Y%m%d)
%else
-%define subver 20110305
+%define subver 20180902
%endif
-%define rel 1
+%define rel 7
%if %{with sqlite}
%undefine sqlite3
License: GPL v2+
Group: Applications/Communications
%if %{without git}
-Source0: https://github.com/leafnode/ekg2/tarball/master#/%{name}-%{subver}.tar.bz2
-# Source0-md5: 31031944a74fd569fbf275111c62a9bc
+Source0: https://github.com/leafnode/ekg2/tarball/master?/%{name}-%{subver}.tar.gz
+# Source0-md5: 2ce452ebcecc03532dee956c5648d890
%endif
Patch0: %{name}-perl-install.patch
Patch1: %{name}-gtk.patch
Patch2: %{name}-bug-63.patch
+Patch3: %{name}-keepalive_irc.patch
+Patch4: openssl.patch
URL: http://ekg2.org/
%{?with_aspell:BuildRequires: aspell-devel}
BuildRequires: autoconf
%if %{with rss} || %{with jabber}
BuildRequires: expat-devel
%endif
-BuildRequires: gettext-devel >= 0.17-8
+BuildRequires: gettext-tools >= 0.17-8
%{?with_gadugadu:BuildRequires: giflib-devel}
%{?with_git:BuildRequires: git-core}
%{?with_gnutls:BuildRequires: gnutls-devel >= 1.2.5}
%{?with_sqlite3:BuildRequires: sqlite3-devel}
%{?with_xosd:BuildRequires: xosd-devel}
BuildRequires: zlib-devel
+Obsoletes: ekg2-plugin-ioctld
+Obsoletes: ekg2-plugin-remote
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
%description plugin-readline -l pl.UTF-8
Interfejs readline.
-%package plugin-remote
-Summary: Remote contol interface
-Summary(pl.UTF-8): Zdalne sterowanie ekg2
-Group: Applications/Communications
-Requires: %{name} = %{epoch}:%{version}-%{release}
-
-%description plugin-remote
-Remote control interface.
-
-%description plugin-remote -l pl.UTF-8
-Zdalne sterowanie ekg2.
-
%package plugin-scripting-perl
Summary: Perl scripting plugin for ekg2
Summary(pl.UTF-8): Wtyczka języka Perl dla ekg2
git checkout FETCH_HEAD
%else
%setup -q -c -n %{name}-%{subver}
-mv leafnode-ekg2-*/* .
+%{__mv} ekg2-ekg2-*/* .
%endif
%patch0 -p1
%patch1 -p1
%patch2 -p0
+%if %{with irckeepalive}
+%patch3 -p1
+%endif
+
+%patch4 -p1
touch po/Makefile.in.in
find -name *.c > po/POTFILES.in
%files -f %{name}.lang
%defattr(644,root,root,755)
-%doc NEWS* README.md docs/ekg2book* docs/README docs/TODO docs/*.txt
+%doc README.md docs/ekg2book* docs/README docs/TODO docs/*.txt
%attr(755,root,root) %{_bindir}/ekg2
%dir %{_libdir}/%{name}
%dir %{_libdir}/%{name}/plugins
%{_datadir}/%{name}/plugins/mail
%attr(755,root,root) %{_libdir}/%{name}/plugins/ncurses.so
%attr(755,root,root) %{_libdir}/%{name}/plugins/ncurses.la
+%attr(755,root,root) %{_libdir}/%{name}/plugins/rc.so
+%attr(755,root,root) %{_libdir}/%{name}/plugins/rc.la
%attr(755,root,root) %{_libdir}/%{name}/plugins/sms.so
%attr(755,root,root) %{_libdir}/%{name}/plugins/sms.la
%dir %{_datadir}/%{name}
%{_datadir}/%{name}/plugins/logs
%{_datadir}/%{name}/plugins/ncurses
%{_datadir}/%{name}/plugins/sms
+%{_datadir}/%{name}/plugins/rc
%dir %{_datadir}/%{name}/scripts
%{_datadir}/%{name}/themes
%dir %{perl_vendorarch}/Ekg2
%{perl_vendorarch}/Ekg2/Irc.pm
%dir %{perl_vendorarch}/auto/Ekg2
-%{perl_vendorarch}/auto/Ekg2/Ekg2.bs
%attr(755,root,root) %{perl_vendorarch}/auto/Ekg2/Ekg2.so
%dir %{perl_vendorarch}/auto/Ekg2/Irc
-%{perl_vendorarch}/auto/Ekg2/Irc/Irc.bs
%attr(755,root,root) %{perl_vendorarch}/auto/Ekg2/Irc/Irc.so
%{_datadir}/%{name}/scripts/*.pl
%endif