+# Conditional build:
+%bcond_without home_etc # don't use home_etc
+#
Summary: Elmo, MUA supporting Maildirs and Polish language
Summary(pl): Elmo - program pocztowy obs³uguj±cy Maildiry i jêzyk polski
Name: elmo
-Version: 0.7
+Version: 1.2.0
Release: 1
-License: distributable
+License: GPL v2+
+Vendor: Jacek ¦liwerski <rzyj@plusnet.pl>
Group: Applications/Mail
-Source0: http://savannah.nongnu.org/download/elmo/unstable.pkg/%{version}/%{name}-%{version}.tar.gz
+Source0: http://dl.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
+# Source0-md5: 6d2ed7ab5f1cb5ea938819f57d24a419
Source1: %{name}-examplerc
Patch0: %{name}-etc_dir.patch
URL: http://elmo.sourceforge.net/
BuildRequires: autoconf
BuildRequires: automake
+BuildRequires: gettext-devel
BuildRequires: libtool
BuildRequires: ncurses-devel >= 5.0
+%{?with_home_etc:BuildRequires: home-etc-devel}
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
%prep
%setup -q
-#%patch0 -p1
install -m 644 %{SOURCE1} ./examplerc
%build
+%{__gettextize}
%{__libtoolize}
-%{__aclocal} -I .
+%{__aclocal} -I m4
%{__autoconf}
+%{__autoheader}
%{__automake}
-%configure
+%{__automake} m4/Makefile
+%configure \
+ %{?with_home_etc:--with-home-etc}
-%{__make} CC="%{__cc} %{rpmcflags}"
+%{__make} \
+ CC="%{__cc} %{rpmcflags}"
%install
rm -rf $RPM_BUILD_ROOT
+
%{__make} install \
DESTDIR=$RPM_BUILD_ROOT \
docdir=%{_datadir}/%{name}-%{version}
%files -f %{name}.lang
%defattr(644,root,root,755)
-%doc README TODO BUGS THANKS examplerc
+%doc ADVOCACY AUTHORS doc/README.txt doc/sample.* TODO BUGS THANKS examplerc
%attr(755,root,root) %{_bindir}/*
%{_mandir}/man1/*
-%{_infodir}/*.info*