pcsx2: build with gtk3 and support x86_64 builds

wip/yesman
Samuel Gräfenstein 4 years ago
parent 0d5f50e48c
commit d6def694c1
No known key found for this signature in database
GPG Key ID: EF76A063F15C63C8
  1. 37
      pkgs/misc/emulators/pcsx2/default.nix
  2. 4
      pkgs/top-level/all-packages.nix

@ -1,21 +1,19 @@
{ alsaLib, cmake, fetchFromGitHub, glib, gettext, gtk2, harfbuzz, lib, libaio { alsaLib, cmake, fetchFromGitHub, gettext, glib, gtk3, harfbuzz, libaio
, libpng, libpcap, libxml2, makeWrapper, perl, pkgconfig, portaudio , libpcap, libpng, libxml2, makeWrapper, perl, pkgconfig, portaudio, SDL2
, SDL2, soundtouch, stdenv, udev, wxGTK, zlib , soundtouch, stdenv, udev, wrapGAppsHook, wxGTK, zlib
}: }:
stdenv.mkDerivation rec { stdenv.mkDerivation {
pname = "pcsx2"; pname = "pcsx2";
version = "1.6.0"; version = "unstable-2020-10-10";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "PCSX2"; owner = "PCSX2";
repo = "pcsx2"; repo = "pcsx2";
rev = "v${version}"; rev = "7e2ccd64e8e6049b6059141e8767037463421c33";
sha256 = "0528kh3275285lvfsykycdhc35c1z8pmccl2s7dfi3va2cp4x8wa"; sha256 = "0c7m74ch68p4y9xlld34a9r38kb2py6wlkg4vranc6dicxvi1b3r";
}; };
postPatch = "sed '1i#include \"x86intrin.h\"' -i common/src/x86emitter/cpudetect.cpp";
cmakeFlags = [ cmakeFlags = [
"-DCMAKE_INSTALL_PREFIX=${placeholder "out"}" "-DCMAKE_INSTALL_PREFIX=${placeholder "out"}"
"-DDISABLE_ADVANCE_SIMD=TRUE" "-DDISABLE_ADVANCE_SIMD=TRUE"
@ -23,17 +21,14 @@ stdenv.mkDerivation rec {
"-DDOC_DIR=${placeholder "out"}/share/doc/pcsx2" "-DDOC_DIR=${placeholder "out"}/share/doc/pcsx2"
"-DGAMEINDEX_DIR=${placeholder "out"}/share/pcsx2" "-DGAMEINDEX_DIR=${placeholder "out"}/share/pcsx2"
"-DGLSL_SHADER_DIR=${placeholder "out"}/share/pcsx2" "-DGLSL_SHADER_DIR=${placeholder "out"}/share/pcsx2"
"-DwxWidgets_LIBRARIES=${wxGTK}/lib" "-DGTK3_API=TRUE"
"-DwxWidgets_INCLUDE_DIRS=${wxGTK}/include"
"-DwxWidgets_CONFIG_EXECUTABLE=${wxGTK}/bin/wx-config"
"-DPACKAGE_MODE=TRUE" "-DPACKAGE_MODE=TRUE"
"-DPLUGIN_DIR=${placeholder "out"}/lib/pcsx2" "-DPLUGIN_DIR=${placeholder "out"}/lib/pcsx2"
"-DREBUILD_SHADER=TRUE" "-DREBUILD_SHADER=TRUE"
"-DwxWidgets_CONFIG_EXECUTABLE=${wxGTK}/bin/wx-config"
"-DwxWidgets_INCLUDE_DIRS=${wxGTK}/include"
"-DwxWidgets_LIBRARIES=${wxGTK}/lib"
"-DXDG_STD=TRUE" "-DXDG_STD=TRUE"
"-DGTK2_GLIBCONFIG_INCLUDE_DIR=${glib.out}/lib/glib-2.0/include"
"-DGTK2_GDKCONFIG_INCLUDE_DIR=${gtk2.out}/lib/gtk-2.0/include"
"-DGTK2_INCLUDE_DIRS=${gtk2.dev}/include/gtk-2.0"
"-DGTK3_API=FALSE"
]; ];
postFixup = '' postFixup = ''
@ -41,13 +36,13 @@ stdenv.mkDerivation rec {
--set __GL_THREADED_OPTIMIZATIONS 1 --set __GL_THREADED_OPTIMIZATIONS 1
''; '';
nativeBuildInputs = [ cmake makeWrapper perl pkgconfig ]; nativeBuildInputs = [ cmake makeWrapper perl pkgconfig wrapGAppsHook ];
buildInputs = [ buildInputs = [
alsaLib alsaLib
glib
gettext gettext
gtk2 glib
gtk3
harfbuzz harfbuzz
libaio libaio
libpcap libpcap
@ -71,13 +66,13 @@ stdenv.mkDerivation rec {
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 samuelgrf ];
# PCSX2's source code is released under LGPLv3+. It However ships # PCSX2's source code is released under LGPLv3+. It However ships
# additional data files and code that are licensed differently. # additional data files and code that are licensed differently.
# This might be solved in future, for now we should stick with # This might be solved in future, for now we should stick with
# license.free # license.free
license = licenses.free; license = licenses.free;
platforms = platforms.i686; platforms = platforms.x86;
}; };
} }

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

Loading…
Cancel
Save