907c665
# Copyright (c) 2007 oc2pus <toni@links2linux.de>
907c665
# Copyright (c) 2007 Hans de Goede <j.w.r.degoede@hhs.nl>
907c665
# This file and all modifications and additions to the pristine
907c665
# package are under the same license as the package itself.
907c665
#
907c665
# Please submit bugfixes or comments to us at the above email addresses
907c665
907c665
Name:           bolzplatz2006
907c665
Version:        1.0.3
1bb9f5a
Release:        6%{?dist}
907c665
Summary:        Slam Soccer 2006 is a funny football game in 3D-comic-style
907c665
Summary(fr):    Coup de Foot 2006 est un jeu comique en 3D
907c665
Summary(de):    Bolzplatz 2006 ist ein spaßiges Fußballspiel im 3D-Comic-Stil
907c665
License:        GPLv2+
907c665
Group:          Amusements/Games
907c665
URL:            http://www.bolzplatz2006.de
907c665
Source0:        http://downloads.sourceforge.net/bp2k6/%{name}-%{version}-src.zip
907c665
Source1:        %{name}.png
907c665
Source2:        %{name}.sh
907c665
Source3:        %{name}-settings.sh
907c665
Source4:        %{name}.desktop
907c665
Source5:        %{name}-settings.desktop
907c665
Source6:        %{name}-jirr-no-crash.patch
907c665
Source7:        %{name}-functions.sh
907c665
Source8:        %{name}.autodlrc
907c665
Source9:        input.xml
907c665
Patch0:         %{name}-irrlicht.i.patch
907c665
Patch1:         %{name}-irrlicht-extra-qualification-error.patch
907c665
Patch2:         %{name}-irrlicht-use-systemlibs.patch
907c665
Patch3:         %{name}-irrlicht-png-64bit.patch
907c665
Patch4:         %{name}-lwjgl-nofmod.patch
907c665
Patch5:         %{name}-lwjgl-openal11.patch
907c665
Patch6:         %{name}-lwjgl-Makefile.patch
907c665
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
907c665
BuildRequires:  ant-nodeps sdljava dom4j vecmath1.2 swig xml-commons-apis
907c665
BuildRequires:  libGLU-devel DevIL-devel libXxf86vm-devel libjpeg-devel
907c665
BuildRequires:  libpng-devel libXext-devel libXrandr-devel libXcursor-devel
907c665
BuildRequires:  libXt-devel libXrender-devel libvorbis-devel desktop-file-utils
6c11291
# Building ( & running) only works with openjdk
6c11291
BuildRequires:  java-1.6.0-openjdk-devel
6c11291
Requires:       sdljava dom4j vecmath1.2 java-1.6.0-openjdk jpackage-utils
907c665
Requires:       hicolor-icon-theme autodownloader
907c665
907c665
%description
907c665
Slam Soccer 2006 is a funny football game in
907c665
3D-comic-style - and it's for free!
907c665
907c665
* Freeware and open source
907c665
* Funny 3d-comic-style
907c665
* Enthralling stadium atmosphere
907c665
* Keyboard and gamepad control
907c665
* 2-player mode
907c665
* Career and world cup
907c665
* Register in the online hall of fame
907c665
* Build your own stadium
907c665
907c665
* 80 teams
907c665
* 20 stadiums
907c665
* 10 weather conditions
907c665
* 50 adboards
907c665
* 10 referees
907c665
* 9 commentators (5 German, 2 English, 2 French)
907c665
907c665
* 3 languages: German, English, French
907c665
907c665
%description -l de
907c665
Bolzplatz 2006 ist ein spaßiges Fußballspiel
907c665
im 3D-Comic-Stil für lau.
907c665
907c665
* Kostenlos und Open-Source
907c665
* Witzige 3D-Comic-Grafik
907c665
* Packende Stadionatmosphäre
907c665
* Steuerung mit Tastatur oder Gamepad
907c665
* 2-Spieler-Modus
907c665
* Karriere und Weltmeisterschaft
907c665
* Eintrag in die Hall of Fame
907c665
* Baue Dein eigenes Stadion
907c665
907c665
* 80 Teams
907c665
* 20 Stadien
907c665
* 10 Wetterverhältnisse
907c665
* 50 Werbebanden
907c665
* 10 Schiedsrichter
907c665
* 9 Kommentatoren (5xDeutsch, 2xEnglisch, 2xFranzösisch)
907c665
907c665
* 3 Sprachen: Deutsch, Englisch und Französisch
907c665
907c665
%description -l fr
907c665
Coup de Foot 2006 est un jeu comique en 3D.
907c665
Gratuit et open-source.
907c665
907c665
* Graphiques 3D en style cartoon
907c665
* Ambiance de stade presqu'originale
907c665
* A commander par clavier ou gamepad
907c665
* Mode 2 joueurs
907c665
* Mode Carrière et Coupe du Monde
907c665
* Inscription au Hall of Fame
907c665
* Construis tes propres stades
907c665
907c665
* 80 équipes
907c665
* 20 stades
907c665
* 10 conditions atmosphériques différentes
907c665
* 50 panneaux publicitaires
907c665
* 10 arbitres
907c665
* 9 commentateurs
907c665
907c665
* 3 langues: allemand, anglais et français
907c665
907c665
907c665
%prep
907c665
%setup -q -c
907c665
pushd libsrc/jirr-dev
907c665
%patch0 -p0
907c665
cp %{SOURCE6} diff.txt
907c665
popd
907c665
%patch1 -p1
907c665
%patch2 -p1
907c665
%patch3 -p1
907c665
%patch4 -p1
907c665
%patch5 -p1
907c665
%patch6 -p1
907c665
sed -i 's/\r//' license.txt
907c665
# we use the system versions of these
907c665
rm -r libsrc/irrlicht-0.14-patched/libpng libsrc/irrlicht-0.14-patched/zlib \
907c665
  libsrc/irrlicht-0.14-patched/jpeglib
907c665
907c665
907c665
%build
1bb9f5a
export RPM_OPT_FLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE"
6c11291
export JAVA_HOME=/usr/lib/jvm/java-openjdk
907c665
6c11291
# special case ix86 as all of ix86 should look in the i386 jre lib subdir
907c665
%ifarch %{ix86}
907c665
export JAVA_ARCH=i386
907c665
%endif
6c11291
# special case x86_64 as it should be mapped to amd64
907c665
%ifarch x86_64
907c665
export JAVA_ARCH=amd64
907c665
%endif
6c11291
# All other archs
6c11291
if [ -z "$JAVA_ARCH" ]; then
6c11291
  export JAVA_ARCH=%{_arch}
6c11291
fi
907c665
907c665
# jbolzplatz ships with copies of several libraries, as these are heavily
907c665
# patched we use the bolzplatz versions and not the system ones
907c665
907c665
# build irrlicht-0.14
907c665
pushd libsrc/irrlicht-0.14-patched
907c665
make %{?_smp_mflags} CPP="g++ $RPM_OPT_FLAGS -fPIC -fno-strict-aliasing" \
907c665
  CC="g++ $RPM_OPT_FLAGS -fPIC -fno-strict-aliasing"
907c665
popd
907c665
907c665
# build jirr-0.6
907c665
pushd libsrc/jirr-dev
907c665
make CXX="g++ $RPM_OPT_FLAGS -fPIC -fno-strict-aliasing" \
907c665
  CC="g++ $RPM_OPT_FLAGS -fPIC -fno-strict-aliasing"
907c665
popd
907c665
907c665
# build lwjgl
907c665
pushd libsrc/lwjgl
907c665
ant jars
907c665
ant compile_native
907c665
popd
907c665
907c665
# build bolzplatz itself
907c665
mkdir classes
907c665
javac -d classes -encoding iso-8859-1 \
907c665
  -cp `build-classpath dom4j sdljava vecmath`:./libsrc/jirr-dev/lib/irrlicht.jar:./libsrc/lwjgl/libs/lwjgl.jar \
907c665
  `find ./src -name '*.java'`
907c665
jar cf %{name}.jar -C classes .
907c665
907c665
907c665
%install
907c665
rm -rf $RPM_BUILD_ROOT
907c665
907c665
# dirs
907c665
mkdir -p $RPM_BUILD_ROOT%{_bindir}
907c665
mkdir -p $RPM_BUILD_ROOT%{_libdir}/%{name}
907c665
mkdir -p $RPM_BUILD_ROOT%{_datadir}/%{name}
907c665
mkdir -p $RPM_BUILD_ROOT%{_javadir}/%{name}
907c665
mkdir -p $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/16x16/apps
907c665
907c665
# jars
907c665
install -m 644 %{name}.jar libsrc/jirr-dev/lib/irrlicht.jar \
907c665
  libsrc/lwjgl/libs/lwjgl.jar $RPM_BUILD_ROOT%{_javadir}/%{name}
907c665
907c665
# native libraries
907c665
install -m 755 libsrc/jirr-dev/libirrlicht_wrap.so \
907c665
  libsrc/lwjgl/libs/linux/liblwjgl.so $RPM_BUILD_ROOT%{_libdir}/%{name}
907c665
907c665
# startscripts
907c665
install -m 755 %{SOURCE2} $RPM_BUILD_ROOT%{_bindir}/%{name}
907c665
install -m 755 %{SOURCE3} $RPM_BUILD_ROOT%{_bindir}/%{name}-settings
907c665
907c665
# icon and menu-entry
907c665
install -p -m 644 %{SOURCE1} \
907c665
  $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/16x16/apps
907c665
desktop-file-install --vendor fedora            \
907c665
  --dir $RPM_BUILD_ROOT%{_datadir}/applications \
907c665
  %{SOURCE4}
907c665
desktop-file-install --vendor fedora            \
907c665
  --dir $RPM_BUILD_ROOT%{_datadir}/applications \
907c665
  %{SOURCE5}
907c665
907c665
# needed "data" files
907c665
install -p -m 644 %{SOURCE7} %{SOURCE8} %{SOURCE9} \
907c665
  $RPM_BUILD_ROOT%{_datadir}/%{name}
907c665
907c665
907c665
%clean
907c665
rm -rf $RPM_BUILD_ROOT
907c665
907c665
907c665
%post
907c665
touch --no-create %{_datadir}/icons/hicolor || :
907c665
if [ -x %{_bindir}/gtk-update-icon-cache ]; then
907c665
   %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
907c665
fi
907c665
907c665
%postun
907c665
touch --no-create %{_datadir}/icons/hicolor || :
907c665
if [ -x %{_bindir}/gtk-update-icon-cache ]; then
907c665
   %{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
907c665
fi
907c665
907c665
907c665
%files
907c665
%defattr(-,root,root,-)
907c665
%doc license.txt
907c665
%{_bindir}/%{name}*
907c665
%{_libdir}/%{name}
907c665
%{_datadir}/%{name}
907c665
%{_javadir}/%{name}
907c665
%{_datadir}/applications/fedora-%{name}*.desktop
907c665
%{_datadir}/icons/hicolor/16x16/apps/%{name}.png
907c665
907c665
907c665
%changelog
1bb9f5a
* Wed Apr  2 2008 Hans de Goede <j.w.r.degoede@hhs.nl> 1.0.3-6
1bb9f5a
- Fix missing prototype compiler warnings
1bb9f5a
6c11291
* Fri Mar 14 2008 Hans de Goede <j.w.r.degoede@hhs.nl> 1.0.3-5
6c11291
- Adapt launch script and (Build)Requires for icedtea -> openjdk rename
6c11291
- Drop ExclusiveArch now that openjdk also is available for ppc
6c11291
388907b
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 1.0.3-4
388907b
- Autorebuild for GCC 4.3
388907b
907c665
* Thu Nov 29 2007 Hans de Goede <j.w.r.degoede@hhs.nl> 1.0.3-3
907c665
- Add missing BuildRequires: libXxf86vm-devel, libGLU-devel, libjpeg-devel,
907c665
  libpng-devel, libXext-devel, libXrandr-devel, libXcursor-devel, libXt-devel
907c665
  libXrender-devel, libvorbis-devel, desktop-file-utils
907c665
907c665
* Mon Sep 17 2007 Hans de Goede <j.w.r.degoede@hhs.nl> 1.0.3-2
907c665
- Switch to using autodownloader for the datafiles, upstream wanted to change
907c665
  the license of the datafiles to be free, but not all contributers have
907c665
  agreed to the license change :(
907c665
907c665
* Sat Sep  8 2007 Hans de Goede <j.w.r.degoede@hhs.nl> 1.0.3-1
907c665
- Adapted Packman spec file for Fedora
907c665
907c665
* Mon Jun 18 2007 Toni Graffy <toni@links2linux.de> - 1.0.3-0.pm.1
907c665
- initial release 1.0.3
907c665
- repacked as tar.bz2
907c665
- added docs from binary-tarball