File supertux.spec of Package supertux

#
# spec file for package supertux
#
# Copyright (c) 2016 SUSE LINUX 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:           supertux
Version:        0.1.3
Release:        0
Summary:        Jump'n run game
License:        GPL-2.0+
Group:          Amusements/Games/Action/Arcade
Url:            https://supertuxproject.org/
Source:         https://github.com/SuperTux/supertux/releases/download/v%{version}/supertux-%{version}.tar.bz2
# PATCH-FIX-UPSTREAM supertux-gcc41.patch -- Fix some problems with gcc 4.1 or newer
Patch0:         %{name}-gcc41.patch
# PATCH-FIX-UPSTREAM supertux-missing-return.patch -- Fix nonvoid functions without default return
Patch1:         %{name}-missing-return.patch
# PATCH-FIX-UPSTREAM supertux-gcc6.patch -- Fix some problems with gcc >= 6
Patch2:         %{name}-gcc6.patch
BuildRequires:  xorg-x11-devel
BuildRequires:  libSDL_image-devel
BuildRequires:  libSDL_mixer-devel
BuildRequires:  libmikmod-devel
BuildRequires:  fdupes
BuildRequires:  gcc-c++
BuildRequires:  update-desktop-files
BuildRequires:  zlib-devel
# needed to be specified explicitly
Requires:       libmikmod
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
SuperTux is a classic 2D jump'n run sidescroller game in a similar
style like the original SuperMario games.

%prep
%setup -q
%patch0
%patch1
%patch2 -p1

%build
%configure \
  --disable-debug
make %{?_smp_mflags}

%install
make %{?_smp_mflags} DESTDIR=%{buildroot} install
%suse_update_desktop_file %{name}
%fdupes %{buildroot}%{_datadir}

%files
%defattr(-,root,root)
%doc AUTHORS COPYING ChangeLog LEVELDESIGN NEWS README
%{_bindir}/supertux
%{_datadir}/supertux/
%{_datadir}/applications/%{name}.desktop
%{_datadir}/pixmaps/%{name}.png

%changelog
openSUSE Build Service is sponsored by