File melonds.spec of Package melonds
#
# Spec file for package melonDS
#
# Copyright © 2019–2022 Markus S. <kamikazow@opensuse.org>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
%define _localname melonDS
Name: melonds
Summary: Nintendo DS emulator
Version: 0.9.5
Release: 0
License: GPL-3.0-or-later
URL: http://melonds.kuribo64.net/
Source0: https://github.com/Arisotura/melonDS/archive/%{version}.tar.gz#/%{_localname}-%{version}.tar.gz
Patch0: fix-wayland-include.patch
Patch1: confirm-reset.patch
BuildRequires: cmake
BuildRequires: extra-cmake-modules
BuildRequires: gcc-c++
BuildRequires: hicolor-icon-theme
BuildRequires: ninja
BuildRequires: pkgconfig
BuildRequires: update-desktop-files
BuildRequires: libarchive-devel
BuildRequires: libcurl-devel
BuildRequires: libpcap-devel
BuildRequires: libslirp-devel
BuildRequires: pkgconfig(gtk+-3.0)
BuildRequires: pkgconfig(Qt5Core)
BuildRequires: pkgconfig(Qt5Multimedia)
BuildRequires: pkgconfig(Qt5Network)
BuildRequires: pkgconfig(Qt5OpenGL)
BuildRequires: pkgconfig(Qt5WaylandClient)
BuildRequires: pkgconfig(Qt5Widgets)
BuildRequires: pkgconfig(sdl2)
BuildRequires: pkgconfig(wayland-client)
BuildRequires: pkgconfig(wayland-egl)
BuildRequires: pkgconfig(wayland-egl-backend)
BuildRequires: pkgconfig(wayland-protocols)
BuildRequires: pkgconfig(wayland-server)
BuildRequires: libQt5Gui-private-headers-devel
%description
melonDS is a Nintendo DS emulator.
%prep
%autosetup -p1 -n %{_localname}-%{version}
%build
export LDFLAGS="-Wl,-z,noexecstack"
mkdir build
cd build
cmake \
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
-G "Ninja" \
..
ninja -v
%install
cd build
DESTDIR=%{buildroot} ninja install
%files
%defattr(-,root,root,-)
%doc README.md
%license LICENSE
%{_bindir}/%{_localname}
%{_datadir}/applications/net.kuribo64.melonDS.desktop
%{_datadir}/icons/hicolor/*/apps/net.kuribo64.melonDS.png
%changelog