diff options
Diffstat (limited to 'pkgs/misc/emulators/desmume/default.nix')
-rw-r--r-- | pkgs/misc/emulators/desmume/default.nix | 93 |
1 files changed, 61 insertions, 32 deletions
diff --git a/pkgs/misc/emulators/desmume/default.nix b/pkgs/misc/emulators/desmume/default.nix index 03e97743905..2e959c756e3 100644 --- a/pkgs/misc/emulators/desmume/default.nix +++ b/pkgs/misc/emulators/desmume/default.nix @@ -1,45 +1,75 @@ -{ lib, stdenv, fetchurl, fetchpatch -, pkg-config, libtool, intltool +{ lib +, stdenv +, fetchFromGitHub +, SDL2 +, agg +, alsa-lib +, desktop-file-utils +, gtk3 +, intltool +, libGLU , libXmu +, libpcap +, libtool , lua +, meson +, ninja +, openal +, pkg-config +, soundtouch , tinyxml -, agg, alsa-lib, soundtouch, openal -, desktop-file-utils -, gtk2, gtkglext, libglade -, libGLU, libpcap, SDL, zziplib }: +, zlib +}: -with lib; stdenv.mkDerivation rec { - pname = "desmume"; - version = "0.9.11"; + version = "0.9.11+unstable=2021-09-22"; - src = fetchurl { - url = "mirror://sourceforge/project/desmume/desmume/${version}/${pname}-${version}.tar.gz"; - sha256 = "15l8wdw3q61fniy3h93d84dnm6s4pyadvh95a0j6d580rjk4pcrs"; + src = fetchFromGitHub { + owner = "TASVideos"; + repo = pname; + rev = "7fc2e4b6b6a58420de65a4089d4df3934d7a46b1"; + hash = "sha256-sTCyjQ31w1Lp+aa3VQ7/rdLbhjnqthce54mjKJZQIDM="; }; - patches = [ - ./gcc6_fixes.patch - ./gcc7_fixes.patch - ./01_use_system_tinyxml.patch + nativeBuildInputs = [ + desktop-file-utils + intltool + libtool + lua + meson + ninja + pkg-config + ]; + + buildInputs = [ + SDL2 + agg + alsa-lib + gtk3 + libGLU + libXmu + libpcap + openal + soundtouch + tinyxml + zlib ]; - CXXFLAGS = "-fpermissive"; + hardeningDisable = [ "format" ]; - buildInputs = - [ pkg-config libtool intltool libXmu lua agg alsa-lib soundtouch - openal desktop-file-utils gtk2 gtkglext libglade - libGLU libpcap SDL zziplib tinyxml ]; + preConfigure = '' + cd desmume/src/frontend/posix + ''; - configureFlags = [ - "--disable-glade" # Failing on compile step - "--enable-openal" - "--enable-glx" - "--enable-hud" - "--enable-wifi" ]; + mesonFlags = [ + "-Db_pie=true" + "-Dopenal=true" + "-Dwifi=true" + ]; - meta = { + meta = with lib; { + homepage = "http://www.desmume.com"; description = "An open-source Nintendo DS emulator"; longDescription = '' DeSmuME is a freeware emulator for the NDS roms & Nintendo DS @@ -48,10 +78,9 @@ stdenv.mkDerivation rec { roms. DeSmuME is also able to emulate nearly all of the commercial nds rom titles which other DS Emulators aren't. ''; - homepage = "http://www.desmume.com"; - license = licenses.gpl1Plus; + license = licenses.gpl2Plus; maintainers = [ maintainers.AndersonTorres ]; - platforms = platforms.linux; + platforms = platforms.unix; }; } -# TODO: investigate glade +# TODO: investigate the patches |