Merge pull request #75413 from aanderse/pcsx2

pcsx2: 1.4.0 -> unstable-2020-01-05
This commit is contained in:
Aaron Andersen 2020-01-11 10:42:06 -05:00 committed by GitHub
commit fabd3f506c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 46 additions and 36 deletions

View File

@ -1,58 +1,66 @@
{ alsaLib, cmake, fetchFromGitHub, glib, gtk2, gettext, libaio, libpng { alsaLib, cmake, fetchFromGitHub, glib, gettext, gtk2, harfbuzz, lib, libaio
, makeWrapper, perl, pkgconfig, portaudio, SDL2, soundtouch, stdenv , libpng, libpcap, libxml2, makeWrapper, perl, pkgconfig, portaudio
, wxGTK30, zlib }: , SDL2, soundtouch, stdenv, udev, wxGTK, zlib
}:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
pname = "pcsx2"; pname = "pcsx2";
version = "1.4.0"; version = "unstable-2020-01-05";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "PCSX2"; owner = "PCSX2";
repo = "pcsx2"; repo = "pcsx2";
rev = "v${version}"; rev = "9c12937351c51b921e1f28d44b019bc52e747c51";
sha256 = "0s7mxq2cgzwjfsq0vhpz6ljk7wr725nxg48128iyirf85585l691"; sha256 = "0y1f5v99a6njmf6hyvl4z5xnrm7351rkyw2fn4f09hqn92r7zmi5";
}; };
postPatch = "sed '1i#include \"x86intrin.h\"' -i common/src/x86emitter/cpudetect.cpp"; postPatch = "sed '1i#include \"x86intrin.h\"' -i common/src/x86emitter/cpudetect.cpp";
configurePhase = '' cmakeFlags = [
mkdir -p build "-DCMAKE_INSTALL_PREFIX=${placeholder "out"}"
cd build "-DDISABLE_ADVANCE_SIMD=TRUE"
"-DDISABLE_PCSX2_WRAPPER=TRUE"
cmake \ "-DDOC_DIR=${placeholder "out"}/share/doc/pcsx2"
-DBIN_DIR="$out/bin" \ "-DGAMEINDEX_DIR=${placeholder "out"}/share/pcsx2"
-DCMAKE_BUILD_PO=TRUE \ "-DGLSL_SHADER_DIR=${placeholder "out"}/share/pcsx2"
-DCMAKE_BUILD_TYPE=Release \ "-DwxWidgets_LIBRARIES=${wxGTK}/lib"
-DCMAKE_INSTALL_PREFIX="$out" \ "-DwxWidgets_INCLUDE_DIRS=${wxGTK}/include"
-DDISABLE_ADVANCE_SIMD=TRUE \ "-DwxWidgets_CONFIG_EXECUTABLE=${wxGTK}/bin/wx-config"
-DDISABLE_PCSX2_WRAPPER=TRUE \ "-DPACKAGE_MODE=TRUE"
-DDOC_DIR="$out/share/doc/pcsx2" \ "-DPLUGIN_DIR=${placeholder "out"}/lib/pcsx2"
-DGAMEINDEX_DIR="$out/share/pcsx2" \ "-DREBUILD_SHADER=TRUE"
-DGLSL_SHADER_DIR="$out/share/pcsx2" \ "-DXDG_STD=TRUE"
-DGTK2_GLIBCONFIG_INCLUDE_DIR='${glib.out}/lib/glib-2.0/include' \ "-DGTK2_GLIBCONFIG_INCLUDE_DIR=${glib.out}/lib/glib-2.0/include"
-DGTK2_GDKCONFIG_INCLUDE_DIR='${gtk2.out}/lib/gtk-2.0/include' \ "-DGTK2_GDKCONFIG_INCLUDE_DIR=${gtk2.out}/lib/gtk-2.0/include"
-DGTK2_INCLUDE_DIRS='${gtk2.dev}/include/gtk-2.0' \ "-DGTK2_INCLUDE_DIRS=${gtk2.dev}/include/gtk-2.0"
-DPACKAGE_MODE=TRUE \ "-DGTK3_API=FALSE"
-DPLUGIN_DIR="$out/lib/pcsx2" \ ];
-DREBUILD_SHADER=TRUE \
-DXDG_STD=TRUE \
..
'';
postFixup = '' postFixup = ''
wrapProgram $out/bin/PCSX2 \ wrapProgram $out/bin/PCSX2 \
--set __GL_THREADED_OPTIMIZATIONS 1 --set __GL_THREADED_OPTIMIZATIONS 1
''; '';
nativeBuildInputs = [ cmake perl pkgconfig ]; nativeBuildInputs = [ cmake makeWrapper perl pkgconfig ];
buildInputs = [ buildInputs = [
alsaLib glib gettext gtk2 libaio libpng makeWrapper portaudio SDL2 alsaLib
soundtouch wxGTK30 zlib glib
gettext
gtk2
harfbuzz
libaio
libpcap
libpng
libxml2
portaudio
SDL2
soundtouch
udev
wxGTK
zlib
]; ];
enableParallelBuilding = true;
meta = with stdenv.lib; { meta = with stdenv.lib; {
description = "Playstation 2 emulator"; description = "Playstation 2 emulator";
longDescription= '' longDescription= ''
@ -62,7 +70,7 @@ stdenv.mkDerivation rec {
states and PS2 system memory. This allows you to play PS2 games on your states and PS2 system memory. This allows you to play PS2 games on your
PC, with many additional features and benefits. PC, with many additional features and benefits.
''; '';
homepage = https://pcsx2.net; homepage = "https://pcsx2.net";
maintainers = with maintainers; [ hrdinka ]; maintainers = with maintainers; [ hrdinka ];
# PCSX2's source code is released under LGPLv3+. It However ships # PCSX2's source code is released under LGPLv3+. It However ships

View File

@ -20704,7 +20704,9 @@ in
ffmpeg = ffmpeg_2; ffmpeg = ffmpeg_2;
}; };
pcsx2 = pkgsi686Linux.callPackage ../misc/emulators/pcsx2 { }; pcsx2 = pkgsi686Linux.callPackage ../misc/emulators/pcsx2 {
wxGTK = pkgsi686Linux.wxGTK30;
};
pekwm = callPackage ../applications/window-managers/pekwm { }; pekwm = callPackage ../applications/window-managers/pekwm { };