%define python_sitelib %(%{__python} -c 'from distutils import sysconfig; print sysconfig.get_python_lib()') Name: specto Version: 0.2.0 Release: 4%{?dist} Summary: An desktop application that will watch configurable events Group: Applications/System License: GPL URL: http://specto.sourceforge.net/ Source0: http://specto.googlecode.com/files/%{name}-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch BuildRequires: python-devel BuildRequires: desktop-file-utils Requires: dbus-python, notify-python Requires: pygtk2-libglade Requires: gnome-python2-gconf Requires: gnome-python2-gnomevfs %description Specto is a desktop application that will watch configurable events (such as website updates, emails, file and folder changes, system processes, etc) and then trigger notifications. Specto can watch a website for updates and notify you when there is activity (otherwise, Specto will just stay out of the way). This changes the way you work, because you can be informed of events instead of having to look out for them. %prep %setup -q %build python setup.py build #remove shebang from non-executable files sed -e '/^#!\//,1 d' -i spectlib/*.py #Fix default doc directory. sed -e 's|/share/doc/%{name}/|/share/doc/%{name}-%{version}/|g' \ -i spectlib/util.py %install rm -rf $RPM_BUILD_ROOT python setup.py install --root $RPM_BUILD_ROOT #move docs in better location to add them properly mv data/doc/{AUTHORS,ChangeLog,VERSION,COPYING} . rm -rf $RPM_BUILD_ROOT%{_datadir}/doc/%{name} desktop-file-install \ --vendor "" \ --dir $RPM_BUILD_ROOT/%{_datadir}/applications \ --mode 0644 \ --remove-category=Application \ $RPM_BUILD_ROOT%{_datadir}/applications/%{name}.desktop %find_lang %{name} %clean rm -rf $RPM_BUILD_ROOT %post touch --no-create %{_datadir}/icons/hicolor || : %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || : %postun touch --no-create %{_datadir}/icons/hicolor || : %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || : %files -f %{name}.lang %defattr(-,root,root,-) %doc AUTHORS ChangeLog COPYING VERSION %{_bindir}/%{name} %{_datadir}/icons/hicolor/scalable/apps/%{name}.svg %{_datadir}/%{name} %{_datadir}/applications/%{name}.desktop %{python_sitelib}/spectlib %changelog * Wed Mar 07 2007 Xavier Lamien - 0.2.0-4 - Fixed typing error from sed command. * Tue Mar 06 2007 Xavier Lamien - 0.2.0-3 - Removed 'gnome-python2' as redundant require. - Fixed default doc directory and added VERSION file in it. * Mon Mar 05 2007 Xavier Lamien - 0.2.0-2 - Removed category "Application" from .desktop file. - Removed 'python' and 'glade-python' from Requires tag. - Added python-related requirements. * Wed Feb 14 2007 Xavier Lamien - 0.2.0-1 - Initial RPM release.