%define name kugel %define version 2.7 %define release 4mdk # (misc) perl refuse to run setgid without cleaning the program ( man perlsec ) # therefore, the scorefile cannot be group writeable with the script being setgid on # group games. # (misc) do not change layout of files, rpm will not updgrade cleanly. # see http://archives.mandrakelinux.com/cooker/2004-01/msg00013.php Summary: Kugel, board game Name: %name Version: %version Release: %release License: GPL Group: Games/Boards Source: %name-%version.tar.bz2 Url: http://www.vlptel.com/~vlatko/kugel/kugel.html BuildRoot: %_tmppath/%{name}-buildroot Buildarch: noarch %description The game is played by moving objects on the board and putting them into rows, columns, diagonals. Each time you create a line of the same objects ("kugels", balls...), the score will increment with the number of objects you accomplished to line up. In the same time, the lined up "kugels" will disappear, so you can continue the game with more maneuver space on the board. Any time you fail to create a line of "kugels", new ones will appear on the board. Once the board is full, the game is over. %prep rm -rf $RPM_BUILD_ROOT %setup -q %build #perl -pi -e 's#/usr/games/kugel#%_gamesdatadir/kugel#' kugel %install mkdir -p $RPM_BUILD_ROOT/%_bindir/ mkdir -p $RPM_BUILD_ROOT/%_gamesbindir/kugel mkdir -p $RPM_BUILD_ROOT/%_mandir/man1 chmod a+rw $RPM_BUILD_DIR/%name-%version/scorefile cp -R $RPM_BUILD_DIR/%name-%version/* $RPM_BUILD_ROOT/%_gamesbindir/kugel cp $RPM_BUILD_DIR/%name-%version/kugel $RPM_BUILD_ROOT/%_bindir/kugel cp $RPM_BUILD_DIR/%name-%version/kugel.1.bz2 $RPM_BUILD_ROOT/%_mandir/man1 rm -rf $RPM_BUILD_ROOT/usr/games/kugel/{COPYING,INSTALL,README,TODO,kugel,kugel.spec,kugel.1.bz2} # Menu entry mkdir -p $RPM_BUILD_ROOT%{_menudir} cat >$RPM_BUILD_ROOT%{_menudir}/%{name} <<EOF ?package(%{name}): command="%{_bindir}/%{name}" icon="boards_section.png" needs="X11" \ section="Amusement/Boards" title="Kugel" longtitle="Kugel board game" EOF %post %update_menus %postun %clean_menus %files %defattr(-,root,root) %doc COPYING INSTALL README TODO %_gamesbindir/kugel %_mandir/man1/* %_menudir/* %_bindir/kugel %attr(666,root,root) %_gamesbindir/kugel/scorefile %changelog * Thu Jan 01 2004 Michael Scherer <misc@mandrake.org> 2.7-4mdk - revert to old files layout, to fix upgrade * Wed Dec 31 2003 Michael Scherer <misc@mandrake.org> 2.7-3mdk - fix [DIRM] - add doc - use macro - move to %%_gamesdatadir * Sat Feb 01 2003 Lenny Cartier <lenny@mandrakesoft.com 2.7-2mdk - rebuild * Wed Jan 08 2003 Lenny Cartier <lenny@mandrakesoft.com> 2.7-1mdk - 2.7 * Mon Nov 18 2002 Lenny Cartier <lenny@mandrakesoft.com> 2.6-1mdk - 2.6