Name:           kio_gopher
Summary:        Gopher KIO slave for Konqueror
Version:        0.1.4
Release:        2%{?_dist_release}

Group:          System Environment/Libraries
License:        GPLv2+
URL:            http://kgopher.berlios.de/

Source0:        http://ftp.kde.org/pub/kde/stable/extragear/kio-gopher-%{version}.tar.bz2

BuildRoot:      %{_tmppath}/%{name}-%{version}-root
BuildRequires:  kdelibs4-devel >= 4.3.80
BuildRequires:  cmake
BuildRequires:  gettext

#{?_kde4_macros_api:Requires: kde4-macros(api) = %{_kde4_macros_api} }

%description
This KIO slave adds support for the Gopher protocol to Konqueror.


%prep
%setup -q -n kio-gopher-%{version}

%build
mkdir -p %{_target_platform}
pushd %{_target_platform}
%{cmake} \
    -DCMAKE_BUILD_TYPE=release \
    -DDATA_INSTALL_DIR:PATH=%{_datadir}/kde4/apps \
    -DINCLUDE_INSTALL_DIR:PATH=%{_includedir}/kde4 \
    -DLIBEXEC_INSTALL_DIR:PATH=%{_libexecdir}/kde4 \
    ..
popd

make %{?_smp_mflags} -C %{_target_platform}


%install
rm -rf %{buildroot}
mkdir %{buildroot}
make install DESTDIR=%{buildroot} -C %{_target_platform}

rm -rf %{buildroot}%{_docdir}/HTML

%find_lang kio_gopher


%clean
rm -rf %{buildroot}


%files -f kio_gopher.lang
%defattr(-,root,root,-)
%doc README COPYING BUGS
# FAQ is only about installation problems which shouldn't affect the RPM.
%{_libdir}/kde4/kio_gopher.so
%{_datadir}/kde4/services/gopher.protocol


%changelog
* Fri Sep 02 2016 Toshiaki Ara <ara_t@384.jp> - 0.1.4-2
- rebuild with gcc-5.4.0

* Sun Jan 11 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> - 0.1.4-1
- updated to 0.1.4

* Sun Jan 16 2011 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 0.1.3-4
- Initial build for Vine Linux

* Sat Feb 13 2010 Kevin Kofler <Kevin@tigcc.ticalc.org> - 0.1.3-3
- new tarball from 4.4.0 extragear, contains updates translations

* Wed Sep 16 2009 Kevin Kofler <Kevin@tigcc.ticalc.org> - 0.1.3-2
- drop postfix tag from Release

* Tue Sep 15 2009 Kevin Kofler <Kevin@tigcc.ticalc.org> - 0.1.3-1.kde4.3.1
- Initial Fedora package