%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
Name: pyroom
Version: 0.4.1
Release: 3%{?dist}
Summary: PyRoom is a full screen text editor and a clone of Writeroom
Group: Applications/Editors
License: GPLv3+
URL: http://pyroom.org/
Source0: http://launchpad.net/pyroom/0.4/%{version}/+download/%{name}-%{version}.tar.gz
Patch0: pyroom-locale.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
Requires: python
Requires: pygtk2
Requires: pyxdg
Requires: gnome-python2-gtksourceview
BuildRequires: python-devel
BuildRequires: pygtk2
BuildRequires: desktop-file-utils
BuildRequires: gettext
%description
PyRoom is full-screen text editor, without buttons, menu, formatting,
so you can focus on writing, and only writing. It is written in
Python + GTK. It is also a clone of Writeroom.
%prep
%setup -q
%patch0 -p1
%build
%{__python} setup.py build
%install
rm -rf $RPM_BUILD_ROOT
# %{__python} setup.py install --skip-build --root $RPM_BUILD_ROOT
%{__python} setup.py install --root $RPM_BUILD_ROOT
chmod 755 %{buildroot}/%{python_sitelib}/PyRoom/cmdline.py
desktop-file-install --vendor="" \
--dir=%{buildroot}%{_datadir}/applications \
%{buildroot}/%{_datadir}/applications/pyroom.desktop
gzip pyroom.1
install -p -D %{name}.1.gz %{buildroot}/%{_mandir}/man1/%{name}.1.gz
%find_lang %{name}
%clean
rm -rf $RPM_BUILD_ROOT
%files -f %{name}.lang
%defattr(-,root,root,-)
%doc AUTHORS LICENSE README
%{python_sitelib}/*
%{_bindir}/%{name}
%{_datadir}/%{name}
%{_datadir}/applications/%{name}.desktop
%{_mandir}/man1/%{name}.1.gz
%changelog
* Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 0.4.1-3
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
* Wed Mar 25 2009 Sven Lankes <sven@lank.es> - 0.4.1-1
- new upstream release
- remove desktop-file-patch
- add patch to fix mo-file install (patch received from upstream)
* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3.2-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
* Sat Dec 06 2008 Sven Lankes <sven@lank.es> - 0.3.2-1
- new upstream release
* Mon Dec 01 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.3.1.1-5
- Rebuild for Python 2.6
* Sun Nov 02 2008 Sven Lankes <sven@lank.es> - 0.3.1.1-4
- add manpage to package
* Sat Nov 01 2008 Sven Lankes <sven@lank.es> - 0.3.1.1-3
- add %U to .desktop-file
* Sat Nov 01 2008 Sven Lankes <sven@lank.es> - 0.3.1.1-2
- add missing BR
* Sat Nov 01 2008 Sven Lankes <sven@lank.es> - 0.3.1.1-1
- new upstream Version (closes bz #464325)
- currently doesn't include any translations
- reworked specfile as upstream now supplies a setup.py
* Tue Jul 22 2008 Rahul Sundaram <sundaram@fedoraproject.org> - 0.2.1-3
- add desktop file. fix permissions and source url
* Fri May 30 2008 Rahul Sundaram <sundaram@fedoraproject.org> - 0.2.1-2
- review changes
* Thu May 29 2008 Rahul Sundaram <sundaram@fedoraproject.org> - 0.2.1-1
- initial review