Summary(ja):  ピエロを操って風船を割るゲーム
Summary:      Cute breakout-like game
Name:         circuslinux
Version:      1.0.3
Release:      1%{?_dist_release}
License:      GPL
Group:        Applications/Games
Source:       circuslinux-%{version}.tar.bz2
Source1:      %{name}.desktop
Source2:      %{name}.6.gz
Patch0:       circuslinux-%{version}.dif
Patch1:       circuslinux-1.0.3-config.patch
URL:          http://www.newbreedsoftware.com/circus-linux/
BuildRoot:    %{_tmppath}/%{name}-%{version}-root

Packager:      OOI Keita       <ooik.ovwqlsjxcqwg4dc@privango.jp>
BuildRequires: SDL-devel, SDL_mixer-devel, SDL_image-devel, automake, autoconf
Requires:      SDL, SDL_image, SDL_mixer, libpng, libjpeg
Distribution:  Vine Linux
Vendor:        Project Vine

%description
The object is to move a teeter-totter back and forth across the screen
to bounce clowns into the air. When they reach the top, they pop rows
of balloons, and then fall back down.

%description -l ja
左右にシーソーを動かして、ピエロを跳ばして、風船を割りましょう。
ブロック崩しに似たゲーム。

%prep
%setup
%patch0
%patch1 -p1 -b .config

aclocal
automake --foreign -a
autoconf
CFLAGS="$RPM_OPT_FLAGS" CXXFLAGS="$CFLAGS" \
  ./configure --prefix=%{_prefix} --enable-joystick
make

%install
rm -rf ${RPM_BUILD_ROOT}
make DESTDIR=${RPM_BUILD_ROOT} install
find ${RPM_BUILD_ROOT}/%{_prefix}/share/circuslinux -type f -exec chmod 644 {} \;
rm -rf $RPM_BUILD_ROOT/%{_prefix}/share/doc/circuslinux-*

# add desktop
mkdir -p $RPM_BUILD_ROOT/%{_datadir}/applications
install -m0644 %{SOURCE1} $RPM_BUILD_ROOT/%{_datadir}/applications/circuslinux.desktop

# add desktop icon
mkdir -p $RPM_BUILD_ROOT/%{_datadir}/pixmaps
install -p -m0644 data/images/circuslinux-icon.xpm $RPM_BUILD_ROOT/%{_datadir}/pixmaps/circuslinux.xpm

# add man
mkdir -p $RPM_BUILD_ROOT/%{_datadir}/man/man6/
install -p -m0644 %{SOURCE2} $RPM_BUILD_ROOT/%{_mandir}/man6/circuslinux.6.gz

%clean
rm -rf ${RPM_BUILD_ROOT}

%files
%defattr(-,root,root)
%{_prefix}/bin/*
%{_prefix}/share/circuslinux
%{_datadir}/pixmaps/*.xpm
%{_datadir}/applications/circuslinux.desktop
%{_mandir}/man6/*
%doc AUTHORS.txt COPYING.txt INSTALL.txt README.txt CHANGES.txt 
%doc FAQ.txt README-SDL.txt

%changelog
* Sun Sep 21 2008 Shu KONNO <owa@bg.wakwak.com> 1.0.3-1vl5
- applied new versioning policy, spec in utf-8

* Mon Feb  4 2008 Shu KONNO <owa@bg.wakwak.com> 1.0.3-0vl3
- added circuslinux-1.0.3-config.patch

* Fri Sep 29 2006 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.0.3-0vl2
- rebuilt for Vine Linux 4.0
- changed Group to Applications/Games
- s/Copyright/License/

* Sun Jan 1 2005 OOI Keita <ooik.ovwqlsjxcqwg4dc@privango.jp>
- 1.0.3-0vl1
- based on 1.0.3-1015 SUSE
- add Japanese summary and description
- add man

* Sat Jan 10 2004 - adrian@suse.de
- build as user
* Sun Aug 10 2003 - sndirsch@suse.de
- added desktop file
* Tue May 27 2003 - ro@suse.de
- remove unpackaged files from buildroot
* Tue Feb 26 2002 - nadvornik@suse.cz
- fixed file permissions in /usr/share/circuslinux
* Fri Feb 01 2002 - ro@suse.de
- changed neededforbuild <libpng> to <libpng-devel-packages>
* Tue Jan 22 2002 - ro@suse.de
- changed neededforbuild <kdelibs-artsd> to <kdelibs3-artsd>
* Wed Nov 07 2001 - nadvornik@suse.cz
- fixed to compile with new automake
- fixed neededforbuild for sound
* Wed Aug 08 2001 - ro@suse.de
- changed neededforbuild <kdelibs kdelibs-devel> to <kdelibs-artsd>
* Wed Aug 08 2001 - ro@suse.de
- changed neededforbuild <sdl> to <SDL>
- changed neededforbuild <sdl-devel> to <SDL-devel>
* Fri Jul 27 2001 - nadvornik@suse.cz
- update to 1.0.3
* Wed Jun 20 2001 - nadvornik@suse.cz
- added kdelibs and kdelibs-devel to neededforbuild
* Mon Mar 26 2001 - ro@suse.de
- changed neededforbuild <sdl> to <sdl sdl-devel>
* Thu Mar 22 2001 - nadvornik@suse.cz
- used suse_update_config
* Fri Mar 09 2001 - ro@suse.de
- neededforbuild sdlmixer -> SDL_mixer
* Wed Feb 21 2001 - nadvornik@suse.cz
- added alsa, alsa-devel to neededforbuild
* Fri Dec 01 2000 - nadvornik@suse.cz
- new packages
