3
0
Fork 0
forked from mirrors/nixpkgs

snes9x: 1.61 -> 1.62

This commit is contained in:
Konrad Borowski 2023-03-25 11:35:49 +01:00
parent b944d5859e
commit 989c5aa9ea

View file

@ -1,23 +1,28 @@
{ lib
, stdenv
, alsa-lib
, autoreconfHook
, cmake
, fetchFromGitHub
, fetchpatch
, gtkmm3
, libepoxy
, libpng
, libselinux
, libX11
, libXv
, libXdmcp
, libXext
, libXinerama
, meson
, libXrandr
, libXv
, minizip
, ninja
, pcre2
, pkg-config
, portaudio
, pulseaudio
, python3
, SDL2
, util-linuxMinimal
, wrapGAppsHook
, zlib
, withGtk ? false
@ -29,40 +34,37 @@ stdenv.mkDerivation rec {
"snes9x-gtk"
else
"snes9x";
version = "1.61";
version = "1.62";
src = fetchFromGitHub {
owner = "snes9xgit";
repo = "snes9x";
rev = version;
fetchSubmodules = true;
sha256 = "1kay7aj30x0vn8rkylspdycydrzsc0aidjbs0dd238hr5hid723b";
hash = "sha256-RcxFNmUbJp0rUugWOqQa3Sy/Hh18ZPOeDTxC0JY5GJQ=";
};
patches = [
# Fix cross-compilation, otherwise it fails to detect host compiler features
# Doesn't affect non CC builds
(fetchpatch {
url = "https://mirror.its.dal.ca/gentoo-portage/games-emulation/snes9x/files/snes9x-1.53-cross-compile.patch";
sha256 = "sha256-ZCmnprimz8PtDIXkB1dYD0oura9icW81yKvJ4coKaDg=";
url = "https://github.com/snes9xgit/snes9x/commit/f39ab408f4151c16d44e45470cc0736ffb2803f8.patch";
hash = "sha256-GMlHBsADEF+rycmEVgpWy220hZwld5D2e8fsYA7HblM=";
})
];
nativeBuildInputs = [
pkg-config
]
++ lib.optionals (!withGtk) [
autoreconfHook
python3
]
++ lib.optionals withGtk [
meson
cmake
ninja
wrapGAppsHook
];
buildInputs = [
libX11
libXext
libXv
minizip
zlib
@ -74,13 +76,19 @@ stdenv.mkDerivation rec {
]
++ lib.optionals (!withGtk) [
libpng
libXext
libXinerama
]
++ lib.optionals withGtk [
gtkmm3
libepoxy
libselinux
libXdmcp
libXrandr
pcre2
portaudio
SDL2
util-linuxMinimal # provides libmount
];
configureFlags =
@ -98,8 +106,7 @@ stdenv.mkDerivation rec {
runHook postInstall
'';
preAutoreconf = lib.optionalString (!withGtk) "cd unix";
preConfigure = lib.optionalString withGtk "cd gtk";
preConfigure = if withGtk then "cd gtk" else "cd unix";
enableParallelBuilding = true;