%define _version 1.10.4
Name:		uget
Version:	%{_version}
Release:	1%{?_dist_release}
Summary:	Uget is a download manager that using gtk and curl
Summary(ja):	Uget - gtk と curl を用いたダウンロードマネージャー

Group:		Applications/Internet
License:	LGPLv2+
URL:		http://urlget.sourceforge.net/
Source0:	http://downloads.sourceforge.net/urlget/%{name}-%{_version}.tar.gz

BuildRoot:	%{_tmppath}/%{name}-%{version}-root

BuildRequires: desktop-file-utils gettext
BuildRequires: glib2-devel => 2.32 openldap-devel
BuildRequires: curl-devel => 7.19.1
BuildRequires: perl-XML-Parser
BuildRequires: gstreamer-devel libnotify-devel
BuildRequires: gtk3-devel >= 3.4


%description
Uget is a download manager that using gtk+ and curl.

%description -l ja
Uget は gtk と curl を用いたダウンロードマネージャーです。

%prep
%setup -q -n %{name}-%{version}

%build
%configure --disable-plugin-aria2 --enable-appindicator=no

make -k %{?_smp_mflags}

%install
rm -rf $RPM_BUILD_ROOT
make install \
	DESTDIR=$RPM_BUILD_ROOT \
	INSTALL="install -p"

%find_lang %{name}

desktop-file-install \
        --dir $RPM_BUILD_ROOT%{_datadir}/applications/ \
        %{name}-gtk.desktop

%clean
rm -rf $RPM_BUILD_ROOT

%post
touch --no-create %{_datadir}/icons/hicolor || :
%{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
update-desktop-database > /dev/null 2>&1 || :


%postun
touch --no-create %{_datadir}/icons/hicolor || :
%{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
update-desktop-database > /dev/null 2>&1 || :

%files -f %{name}.lang
%defattr(-,root,root,-)
%doc COPYING ChangeLog README
%{_bindir}/%{name}-gtk
%{_datadir}/applications/%{name}-gtk.desktop
%{_datadir}/icons/*
%{_datadir}/pixmaps/*
%{_datadir}/sounds/*

%changelog
* Sat Mar 08 2014 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.10.4-1
- new upstream release

* Sat Feb 09 2013 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.10.3-1
- new upstream release

* Sun Oct 28 2012 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.10.2-1
- new upstream release

* Sat Sep 29 2012 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.10.1-1
- new upstream release

* Sat Sep 08 2012 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.10-1
- new upstream release
- changed BuildRequires: gtk3-devel to >= 3.4, glib2-devel => 2.22 to 2.32
- disabled conditional branch
  - because needed gtk3-3.4+
- delted %%configure option --with-gtk3

* Tue May 29 2012 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.8.2-1
- new upstream release

* Sat Apr 28 2012 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.8.1-1
- new upstream release
- set conditional branch for VineSeed and other

* Thu Jun 09 2011 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.8.0-1
- new upstream release
- added %%configure option --disable-plugin-aria2 --enable-appindicator=no

* Thu May 5 2011 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.6.4-1
- new upstream release

* Sun Dec 19 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.6.2a-1
- new upstream release

* Sat Oct 30 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.6.1-1
- new upstream release

* Thu Sep 2 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.6.0-1
- new upstream release
- dropt Pacth1
- changed BuildRequires: gtk2-devel => 2.18, glib2-devel => 2.22, curl-devel => 7.19.1

* Sat Mar 20 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.5.0.3-1
- new upstream release

* Thu Mar 18 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.5.0.2-1
- new upstream release
- applied new naming policy to spec

* Sun Jan 17 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.5.0.1-2
- added Patch1 from Fedora to fix segv when invalid uri is passed to the argument

* Wed Dec 23 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.5.0.1-1
- new upstream release
- added BuildRequires:	gstreamer-devel libnotify-devel

* Thu Oct 8 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.5.0-1
- initial build for VineSeed

* Sat May  2 2009 Mamoru Tasaka <mtasaka@ioa.s.u-tokyo.ac.jp> - 1.4.7-1
- Initial packaging