Sophie

Sophie

distrib > Mageia > 8 > x86_64 > by-pkgid > 6f1ba67ba6339685c5cf62810f68187d > files > 6

brainparty-0.61-9.mga8.src.rpm

Name:		brainparty
Version:	0.61
Release:	%mkrel 9
Summary:	Set of 36 minigames to train your brain in an entertaining way
Group:		Games/Puzzles
# Music files are CC-BY-SA 3.0 or CC-BY-ND 3.0 or Soundsnap License: http://www.soundsnap.com/licence
License:	GPLv3+
URL:		http://www.tuxradar.com/brainparty
Source0:	https://launchpad.net/brainparty/trunk/%{version}/+download/%{name}%{version}.tar.gz
Patch0:		brainparty-0.61-mga-datadir.patch
Patch1:		brainparty-0.61-linking.patch
Patch2:		brainparty-0.61-mga-configfile.patch
# Fix from https://bugs.launchpad.net/brainparty/+bug/1272279
Patch3:		brainparty-0.61-gcc-4.9-default-argument.patch
Patch4:		brainparty-gcc7.patch

BuildRequires:	imagemagick
BuildRequires:	pkgconfig(sdl)
BuildRequires:	pkgconfig(SDL_gfx)
BuildRequires:	pkgconfig(SDL_image)
BuildRequires:	pkgconfig(SDL_mixer)
BuildRequires:	pkgconfig(SDL_ttf)

%description
Brain Party is a fun, free puzzle game for all the family that's made up
of 36 minigames designed to push your brain to its limits by testing
memory, logic, mathematics, reaction time and more! Brain Party is split
into two modes: test mode gives you five minigames in a row and adds up
your brain weight to see how smart you are, and practise mode lets you
play your favourite minigames as often as you want.

%prep
%setup -q -n %{name}
%autopatch -p1

#use our build flags
sed -i -e 's|\(CXXFLAGS =\).*|\1 -c -Wno-deprecated %{optflags}|g' Makefile
sed -i -e '/CXXFLAGS =/ i \\tLDFLAGS = %{ldflags}' Makefile

%build
%make

# Desktop entry
cat > %{name}.desktop << EOF
[Desktop Entry]
Name=Brain Party
Comment=Fun brain training with 36 minigames
Exec=%{name}
Icon=%{name}
Terminal=false
Type=Application
Categories=Game;LogicGame;
EOF

%install
install -D -m0755 %{name} %{buildroot}%{_gamesbindir}/%{name}
mkdir -p %{buildroot}%{_gamesdatadir}/%{name}
install -m0644 Content/* %{buildroot}%{_gamesdatadir}/%{name}/
install -D -m0755 %{name}.desktop %{buildroot}%{_datadir}/applications/%{name}.desktop

for size in 16 32 64; do
    convert ./Content/icon.bmp -resize ${size}x${size} %{name}-${size}.png
    install -D -m0644 %{name}-${size}.png %{buildroot}%{_iconsdir}/hicolor/${size}x${size}/apps/%{name}.png
done

%files
%doc CREDITS README
%{_datadir}/applications/%{name}.desktop
%{_gamesbindir}/%{name}
%{_gamesdatadir}/%{name}/
%{_iconsdir}/hicolor/*/apps/%{name}.png


%changelog
* Wed Feb 12 2020 umeabot <umeabot> 0.61-9.mga8
+ Revision: 1510774
- Mageia 8 Mass Rebuild

* Sat Sep 22 2018 umeabot <umeabot> 0.61-8.mga7
+ Revision: 1295659
- Mageia 7 Mass Rebuild

* Mon Sep 25 2017 cjw <cjw> 0.61-7.mga7
+ Revision: 1159759
- patch4: fix build with gcc 7

* Sat Feb 06 2016 umeabot <umeabot> 0.61-6.mga6
+ Revision: 941383
- Mageia 6 Mass Rebuild

* Wed Oct 15 2014 umeabot <umeabot> 0.61-5.mga5
+ Revision: 748769
- Second Mageia 5 Mass Rebuild

* Tue Sep 16 2014 umeabot <umeabot> 0.61-4.mga5
+ Revision: 678215
- Mageia 5 Mass Rebuild

* Sun Jun 22 2014 akien <akien> 0.61-3.mga5
+ Revision: 638630
- Add an upstream patch to fix building with gcc 4.9

* Sun Mar 23 2014 akien <akien> 0.61-2.mga5
+ Revision: 606745
- Add desktop entry and icon
- Rename scores file
- Patched code to put config file in HOME/.config instead of build dir
- imported package brainparty
+ wally <wally>
- use our build time flags
- add patch to use %%ldflags and fix linking order