diff --git a/pkgs/misc/emulators/mupen64plus/default.nix b/pkgs/misc/emulators/mupen64plus/default.nix new file mode 100644 index 000000000000..8aa0cde02ef9 --- /dev/null +++ b/pkgs/misc/emulators/mupen64plus/default.nix @@ -0,0 +1,23 @@ +{stdenv, fetchurl, which, pkgconfig, SDL, gtk, mesa, SDL_ttf}: + +stdenv.mkDerivation { + name = "mupen64plus-1.5"; + src = fetchurl { + url = http://mupen64plus.googlecode.com/files/Mupen64Plus-1-5-src.tar.gz; + sha256 = "0gygfgyr2sg4yx77ijk133d1ra0v1yxi4xjxrg6kp3zdjmhdmcjq"; + }; + + buildInputs = [ which pkgconfig SDL gtk mesa SDL_ttf ]; + + preConfigure = '' + # Some C++ incompatibility fixes + sed -i -e 's|char \* extstr = strstr|const char * extstr = strstr|' glide64/Main.cpp + sed -i -e 's|char \* extstr = strstr|const char * extstr = strstr|' glide64/Combine.cpp + + # Fix some hardcoded paths + sed -i -e "s|/usr/local|$out|g" main/main.c + ''; + + buildPhase = "make all"; + installPhase = "PREFIX=$out make install"; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 4ebaeeeeb02f..d4f38f8c42f1 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -7975,6 +7975,8 @@ let mess = callPackage ../misc/emulators/mess { }; + mupen64plus = callPackage ../misc/emulators/mupen64plus { }; + nix = nixStable; nixStable = callPackage ../tools/package-management/nix {