File SameBoy.spec of Package SameBoy

#
# spec file for package SameBoy
#
# Copyright (c) 2024 SUSE LLC
#
# 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/
#


%global lower_name sameboy
Name:           SameBoy
Version:        v1.0
Release:        0
Summary:        User friendly, powerful Game Boy, Game Boy Color and Super Game Boy emulator
Group:          System/Emulators/Other
License:        MIT
URL:            https://sameboy.github.io/
Source:         %{name}-%{version}.tar.gz
BuildRequires:  SDL2-devel
BuildRequires:  clang
BuildRequires:  clang-devel
BuildRequires:  gdk-pixbuf-devel
BuildRequires:  glib2-devel
BuildRequires:  make
BuildRequires:  rgbds
BuildRequires:  pkgconfig(gl)
Requires:       SDL2

%description
SameBoy is a user friendly, powerful and open source Game Boy, Game Boy Color and Super Game Boy emulator for macOS, Windows and Unix-like platforms.
It is extremely accurate and includes a wide range of both powerful debugging features and user-facing features, making it ideal for both casual players and developers.
Of course, it also has every feature one would expect from an emulator - from save states to scaling filters.

Includes a thumbnailer for GNOME as well.

%prep
%autosetup -p1

%build
%make_build sdl tester FREEDESKTOP=1 CONF=release PREFIX=%{_prefix}

%check
./.github/actions/sanity_tests.sh

%install
%make_install FREEDESKTOP=1 CONF=release PREFIX=%{_prefix}
# Fix duplicate license install
rm -f %{buildroot}/%{_datadir}/%{lower_name}/LICENSE

%files
%license LICENSE
%doc README.md CHANGES.md CONTRIBUTING.md build-faq.md
%{_bindir}/sameboy
%{_bindir}/sameboy-thumbnailer
%{_datadir}/%{lower_name}/
%{_datadir}/thumbnailers
%{_datadir}/icons/hicolor/
%{_datadir}/applications/%{lower_name}.desktop
%{_datadir}/mime/%{lower_name}.xml

%changelog
openSUSE Build Service is sponsored by