File toycars.spec of Package toycars

#
# spec file for package toycars
#
# Copyright (c) 2013 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:           toycars
Version:        0.3.10
Release:        0
Summary:        Toy Cars is a physics based 2-D racer
License:        GPL-2.0+
Group:          Amusements/Games/Action/Arcade
Url:            http://toycars.sourceforge.net/
Source:         %{name}-%{version}.tar.gz
Source1:        %{name}.desktop
# PATCH-FIX-UPSTREAM toycars-constchar.patch
Patch0:         %{name}-constchar.patch
# PATCH-FIX-UPSTREAM toycars-list.patch
Patch1:         %{name}-list.patch
# PATCH-FIX-UPSTREAM toycars-gcc47.patch
Patch2:         %{name}-gcc47.patch
# PATCH-FIX-UPSTREAM toycars-FLTK.patch
Patch3:         %{name}-FLTK.patch
BuildRequires:  Mesa-devel
BuildRequires:  SDL-devel
BuildRequires:  SDL_image-devel
BuildRequires:  fltk-devel
BuildRequires:  gcc-c++
BuildRequires:  libjpeg-devel
BuildRequires:  libpng-devel
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
Toy Cars is a physics based 2-D racer.

%prep
%setup -q
%patch0
%patch1
%patch2 -p1
%patch3 -p1
# remove hidden files (like .DS_Store and such)
find -name '.*' -delete

%build
%configure
make %{?_smp_mflags}

%install
make DESTDIR=%{buildroot} install
install -D -m 644 toycars/celica-render.png %{buildroot}%{_datadir}/pixmaps/%{name}.png
install -D -m 644 %{SOURCE1} %{buildroot}%{_datadir}/applications/%{name}.desktop

%files
%defattr(-, root, root)
%{_bindir}/%{name}
%{_bindir}/toycars_track_editor
%{_bindir}/toycars_vehicle_editor
%{_datadir}/%{name}/
%{_datadir}/applications/%{name}.desktop
%{_datadir}/pixmaps/%{name}.png

%changelog
openSUSE Build Service is sponsored by