File pachi.spec of Package pachi
#
# spec file for package pachi
#
# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
Name: pachi
Version: 1.0
Release: 0
License: GPL-2.0+
Summary: A platforms game inspired by games like Manic Miner and Jet Set Willy
Url: http://dragontech.sourceforge.net/
Group: Amusements/Games/Action/Arcade
Source: pachi_source.tgz
Source1: %{name}.desktop
# PATCH-FIX-UPSTREAM pachi_source.diff
Patch0: pachi_source.diff
BuildRequires: SDL_mixer-devel
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: fdupes
BuildRequires: gcc-c++
BuildRequires: libtool
%if 0%{?suse_version}
BuildRequires: update-desktop-files
%endif
%if 0%{?suse_version} > 1320
Requires(pre): user(games)
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
Pachi El Marciano is a cool 2D platform game inspired by the likes of
Manic Miner, Jet Set Willy, and more from the '80s.
%prep
%setup -q -n Pachi
%patch0
%build
%configure
make %{?_smp_mflags}
%install
make DESTDIR=%{buildroot} install
mkdir -p %{buildroot}%{_localstatedir}/games
mv %{buildroot}%{_localstatedir}/lib/games/pachi/data/scores.dat \
%{buildroot}%{_localstatedir}/games/pachi.scores
rm -rf %{buildroot}%{_datadir}/doc
%if 0%{?suse_version}
%suse_update_desktop_file -i %{name} Game ArcadeGame
%endif
%fdupes %{buildroot}%{_datadir}
%files
%defattr(-,root,root,-)
%doc AUTHORS COPYING ChangeLog README
%{_bindir}/%{name}
%{_datadir}/%{name}/
%{_datadir}/applications/%{name}.desktop
%attr(0664,root,games) %{_localstatedir}/games/pachi.scores
%changelog