File pinball-table-gnu.spec of Package pinball-table-gnu

#
# spec file for package pinball-table-gnu
#
# Copyright (c) 2024 SUSE LLC
# Copyright (c) 2021 Frank Kunz
#
# 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 https://bugs.opensuse.org/
#


Name:           pinball-table-gnu
Version:        0.0.20200601
Release:        0
Summary:        GNU Pinball table for emilia pinball
License:        GPL-2.0-only
Group:          Amusements/Games/Action/Arcade
URL:            https://github.com/rzr/pinball-table-gnu/
Source0:        https://github.com/rzr/pinball-table-gnu/archive/%{version}.tar.gz
Patch0:         0001-Fix-race-condition-when-table-is-started.patch
BuildRequires:  gcc-c++
BuildRequires:  libtool
BuildRequires:  pinball-devel
BuildRequires:  pkgconfig
BuildRequires:  pkgconfig(sdl)

%description
GNU Pinball table for emilia pinball

%prep
%autosetup -p1

%build
./bootstrap
%configure --prefix=%{_prefix} --libdir=%{_libdir} --disable-static
%__make %{?_smp_mflags} VERBOSE=1 CXXFLAGS="%{optflags}"

%install
%make_install
# remove development file
rm %{buildroot}%{_libdir}/pinball/lib*.so
# workaround for missing highscores directory
mkdir -p %{buildroot}%{_localstatedir}/games/pinball/gnu/

%check

%files
%doc README.md
%license COPYING
%{_libdir}/pinball/
%{_datadir}/pinball/
%dir %attr(0775,games,games) %{_localstatedir}/games/pinball/gnu/
%ghost %attr(0664,games,games) %{_localstatedir}/games/pinball/gnu/highscores

%changelog
openSUSE Build Service is sponsored by