%define pssver 3.01 %define py_ver %pyver Summary: PySol provides several solitaire card games Name: pysol Version: 4.82 Release: %mkrel 8 License: GPL Group: Games/Cards URL: http://www.oberhumer.com/opensource/pysol/ Source0: %{name}-%{version}.tar.bz2 Source1: http://www.oberhumer.com/opensource/pysol/download/pysol-sound-server-%{pssver}.tar.bz2 Source2: %name-%version-src.tar.bz2 #gw use the pysol.py from the source release instead of the bytecode Patch: pysol-4.81-srcrelease.patch.bz2 Patch1: pysol-4.82-sound.patch.bz2 BuildRoot: %_tmppath/%name-%version-%release-root Requires: tkinter >= 1.5.2 BuildRequires: python-devel >= %{py_ver} BuildRequires: smpeg-devel %description PySol has several solitaire card games, written in 100%% pure Python. It has many features: unlimited undo and redo, load & save games, player statistics, hint system, game plug-ins, and more! Contains: klondike, freecel, spider, golf, etc. %prep %setup -q -a 1 -a 2 %patch -p1 %patch1 cp pysol-sound-server-%pssver/NEWS NEWS.pysol-sound-server cp pysol-sound-server-%pssver/README README.pysol-sound-server %build cd pysol-sound-server-%pssver/src ./configure --libdir=%_libdir %make %install rm -fr %buildroot make prefix=%_prefix bindir=%buildroot%_gamesbindir pkgdatadir=%buildroot%_gamesdatadir/%name install-bin install-data install-man mandir=$RPM_BUILD_ROOT/%{_mandir} perl -pi -e "s%$RPM_BUILD_ROOT/usr%/usr%" $RPM_BUILD_ROOT%_gamesbindir/pysol cd pysol-sound-server-%pssver/src python setup.py install --root=$RPM_BUILD_ROOT cd ../.. # they don't support python 2.4 yet rm -f %buildroot%_gamesdatadir/%name/*pyc mkdir %buildroot%_gamesdatadir/%name/BINARIES cp -r %name-%version/src/* %buildroot%_gamesdatadir/%name/BINARIES cat > $RPM_BUILD_ROOT/%_gamesbindir/pysol << EOF #!/bin/sh exec python %_gamesdatadir/%name/BINARIES/pysol.py --pkgdatadir=%_gamesdatadir/%name/ --bindir=%_gamesdatadir/%name/BINARIES/ ${1+"$@"} echo "$0: running $PYTHON failed !" exit 1 EOF chmod 755 $RPM_BUILD_ROOT/%_gamesbindir/pysol # Menu support mkdir -p $RPM_BUILD_ROOT%{_menudir} cat > $RPM_BUILD_ROOT%{_menudir}/%{name} << EOF ?package(%{name}): needs=x11 section=More Applications/Games/Cards title=PySOL command=%_gamesbindir/pysol icon="cards_section.png" longtitle="All solitaire cards games" xdg="true" EOF mkdir -p $RPM_BUILD_ROOT%{_datadir}/applications cat > $RPM_BUILD_ROOT%{_datadir}/applications/mandriva-%{name}.desktop << EOF [Desktop Entry] Encoding=UTF-8 Name=PySOL Comment=All solitaire cards games Exec=%{name} Icon=cards_section Terminal=false Type=Application StartupNotify=true Categories=X-MandrivaLinux-MoreApplications-Games-Cards;Game;CardGame; EOF %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-, root,root) %doc NEWS* README* %{_gamesdatadir}/pysol/ %{_gamesbindir}/pysol %{_mandir}/man6/pysol.6* %_datadir/applications/mandriva* %{_menudir}/* %{py_platsitedir}/* %post %{update_menus} %postun %{clean_menus} %changelog * Tue Nov 28 2006 Götz Waschk <waschk@mandriva.org> 4.82-8mdv2007.0 + Revision: 88188 - Import pysol * Tue Nov 28 2006 Götz Waschk <waschk@mandriva.org> 4.82-8mdv2007.1 - update file list * Tue Aug 1 2006 Götz Waschk <waschk@mandriva.org> 4.82-7mdv2007.0 - xdg menu * Sun Jan 01 2006 Mandriva Linux Team <http://www.mandrivaexpert.com/> 4.82-6mdk - Rebuild * Tue Apr 26 2005 Götz Waschk <waschk@mandriva.org> 4.82-5mdk - update the pysol sound server to 3.01 * Mon Mar 21 2005 Nicolas Lécureuil <neoclust@mandrake.org> 4.82-4mdk - Fix Spec files (Bug #12763) Thanks to hlomi Fish * Sun Dec 5 2004 Götz Waschk <waschk@linux-mandrake.com> 4.82-3mdk - patch bug 12578 - use the source, there's no python 2.4 bytecode available * Sun Dec 05 2004 Michael Scherer <misc@mandrake.org> 4.82-2mdk - Rebuild for new python * Mon Sep 8 2003 Götz Waschk <waschk@linux-mandrake.com> 4.82-1mdk - don't install sources and old bytecode versions - use shipped bytecode - drop the patch - new version * Mon Aug 25 2003 Götz Waschk <waschk@linux-mandrake.com> 4.81-5mdk - python 2.3 support - fix buildrequires * Tue Aug 12 2003 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 4.81-4mdk - rebuild for new python * Mon Jul 7 2003 Götz Waschk <waschk@linux-mandrake.com> 4.81-3mdk - move files around (fix bug 4152) * Thu May 1 2003 Götz Waschk <waschk@linux-mandrake.com> 4.81-2mdk - fix buildrequires * Wed Dec 11 2002 Götz Waschk <waschk@linux-mandrake.com> 4.81-1mdk - add docs - include soundserver, so it's not noarch anymore - new version * Mon Jul 29 2002 Frederic Crozat <fcrozat@mandrakesoft.com> 4.80-3mdk - Remove NO_XALF in menu entries * Wed Jan 09 2002 David BAUDENS <baudens@mandrakesoft.com> 4.80-2mdk - Fix menu entry with png icons * Fri Dec 21 2001 Frederic Lepied <flepied@mandrakesoft.com> 4.80-1mdk - 4.80 * Tue Sep 11 2001 David BAUDENS <baudens@mandrakesoft.com> 4.72-2mdk - Use new icons * Fri Jun 1 2001 Frederic Lepied <flepied@mandrakesoft.com> 4.72-1mdk - 4.72 * Mon May 7 2001 Frederic Lepied <flepied@mandrakesoft.com> 4.71-1mdk - 4.71 * Thu Apr 12 2001 Frederic Crozat <fcrozat@mandrakesoft.com> 4.70-2mdk - Correct GNOME menu entry * Tue Mar 6 2001 Frederic Lepied <flepied@mandrakesoft.com> 4.70-1mdk - 4.70 * Thu Dec 7 2000 Frederic Lepied <flepied@mandrakesoft.com> 4.60-4mdk - corrected menu entry. * Thu Oct 05 2000 Daouda Lo <daouda@mandrakesoft.com> 4.60-3mdk - provide ln icons - macroz++ * Wed Sep 27 2000 Frederic Lepied <flepied@mandrakesoft.com> 4.60-2mdk - changed dependency from python to tkinter. * Wed Aug 16 2000 Frederic Lepied <flepied@mandrakesoft.com> 4.60-1mdk - 4.60 * Tue Jul 4 2000 Frederic Lepied <flepied@mandrakesoft.com> 4.41-1mdk - 4.41 * Thu Apr 20 2000 Frederic Lepied <flepied@mandrakesoft.com> 4.10-1mdk - first mandrake version. * Wed Jun 30 1999 Rodrigo Parra Novo <rodarvus@conectiva.com> - Fixed a bug in the directory where the pixmap was being put * Thu Jun 10 1999 Conectiva <dist@conectiva.com> - Recompiled with glibc 2.1.x, egcs 1.1.x, rpm 3.0.x and kernel 2.2.x * Sat Jun 05 1999 Wanderlei Antonio Cavassin <cavassin@conectiva.com> - updated to 2.14 * Thu Mar 18 1999 Conectiva <dist@conectiva.com> - i18n wmconfig - added Group, Summary and %description translations * Fri Mar 12 1999 Wanderlei Antonio Cavassin <cavassin@conectiva.com> - initial package