Name:           unrar
Version:        4.0.5
Release:        1%{?_dist_release}
Summary:        Utility for extracting RAR archives (nonfree version)
Summary(ja):    RAR アーカイブを解凍するためのユーティリティ (nonfree version)

License:        Freeware with further limitations
Group:          Applications/Archiving
URL:            http://www.rarlab.com/rar_archiver.htm
Source0:        http://www.rarlab.com/rar/unrarsrc-%{version}.tar.gz
#Patch0:         http://ftp.debian.org/debian/pool/non-free/u/unrar-nonfree/unrar-nonfree_3.5.2-0.1.diff.gz
BuildRoot:      %{_tmppath}/%{name}-%{version}-root

BuildRequires:  sed >= 3.9.5
Conflicts:      unrar-free

%description
The unrar is utility for extracting RAR archives.

%description -l ja
unrar は RAR archives を展開するためのユーティリティです。


%prep
%setup -q -n %{name}
#%patch0 -p1
#sed -i -e 's/\r//g' readme.txt


%build
make %{?_smp_mflags} -f makefile.unix \
  CXX="%{__cxx}" CXXFLAGS="$RPM_OPT_FLAGS" STRIP=:


%install
rm -rf $RPM_BUILD_ROOT
install -Dpm 755 unrar $RPM_BUILD_ROOT%{_bindir}/unrar
#install -Dpm 644 debian/unrar.1 $RPM_BUILD_ROOT%{_mandir}/man1/unrar.1


%clean
rm -rf $RPM_BUILD_ROOT


%files
%defattr(-,root,root,-)
%doc license.txt readme.txt
%{_bindir}/unrar
#%{_mandir}/man1/unrar.1*


%changelog
* Wed Jan 26 2011 Toshiharu Kudoh <toshi.kd2@gmail.com> - 4.0.5-1
- new upstream release

* Thu Jan 6 2011 Toshiharu Kudoh <toshi.kd2@gmail.com> - 4.0.4-1
- new upstream release

* Sat Dec 11 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 4.0.2-1
- new upstream release

* Thu Nov 18 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 4.0.1-1
- new upstream release

* Tue Mar 16 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 3.9.10-1
- new upstream release
- applied new naming policy to spec

* Wed Feb 17 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 3.9.9-1
- new upstream release

* Sun Jan 31 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> - 3.9.8-1
- new upstream release

* Fri Dec 18 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> - 3.9.7-1
- new upstream release

* Sat Aug 22 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> - 3.9.6-1
- new upstream release

* Thu Jul 2 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> - 3.9.5-1
- new upstream release

* Thu Jun 11 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> - 3.9.4-1
- new upstream release

* Fri May 22 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> - 3.9.3-1
- new upstream release
- spec in UTF-8

* Fri May 15 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> - 3.9.2-1
- initial build for VineSeed

* Tue Oct 11 2005 Ville Skyttä <ville.skytta at iki.fi> - 3.5.4-0.lvn.1
- 3.5.4.
- Drop zero Epoch.

* Wed Aug 10 2005 Ville Skyttä <ville.skytta at iki.fi> - 0:3.5.3-0.lvn.1
- 3.5.3.

* Thu May 19 2005 Ville Skyttä <ville.skytta at iki.fi> - 0:3.5.2-0.lvn.1
- 3.5.2.

* Thu Mar 31 2005 Ville Skyttä <ville.skytta at iki.fi> - 0:3.5.1-0.lvn.1
- 3.5.1.

* Wed Nov 24 2004 Ville Skyttä <ville.skytta at iki.fi> - 0:3.4.3-0.lvn.1
- Update to 3.4.3.

* Sun Sep  5 2004 Ville Skyttä <ville.skytta at iki.fi> - 0:3.4.2-0.lvn.1
- Update to 3.4.2, nostrip patch no longer necessary.
- Update Debian patch URL.

* Sat Jul  3 2004 Ville Skyttä <ville.skytta at iki.fi> - 0:3.4.1-0.lvn.1
- Update to 3.4.1 and Debian patch to 3.3.6-2.

* Thu May 20 2004 Ville Skyttä <ville.skytta at iki.fi> - 0:3.3.6-0.lvn.2
- Update Debian patch to 3.3.6-1 (no real changes, just a working URL again).

* Sun Feb  8 2004 Ville Skyttä <ville.skytta at iki.fi> - 0:3.3.6-0.lvn.1
- Update to 3.3.6.

* Mon Jan 19 2004 Ville Skyttä <ville.skytta at iki.fi> - 0:3.3.4-0.lvn.1
- Update to 3.3.4.

* Sat Dec 27 2003 Ville Skyttä <ville.skytta at iki.fi> - 0:3.3.3-0.lvn.1
- Update to 3.3.3.

* Sun Dec 21 2003 Ville Skyttä <ville.skytta at iki.fi> - 0:3.3.2-0.lvn.1
- Update to 3.3.2.

* Wed Nov 26 2003 Ville Skyttä <ville.skytta at iki.fi> - 0:3.3.1-0.lvn.1
- Update to 3.3.1.

* Sun Sep 14 2003 Ville Skyttä <ville.skytta at iki.fi> - 0:3.2.3-0.fdr.1
- Update to 3.2.3.
- Sync with current Fedora spec template.

* Wed Apr 16 2003 Ville Skyttä <ville.skytta at iki.fi> - 0:3.2.1-0.fdr.1
- Update to 3.2.1.

* Sat Apr  5 2003 Ville Skyttä <ville.skytta at iki.fi> - 0:3.2.0-0.fdr.1
- Update to 3.2.0 and current Fedora guidelines.

* Sun Feb  9 2003 Ville Skyttä <ville.skytta at iki.fi> - 3.1.3-1.fedora.1
- First Fedora release, based on Matthias Saou's and PLD work.
