2021-01-17 02:30:45 +00:00
|
|
|
{lib, stdenv, fetchFromGitHub, scons, zlib, SDL, lua5_1, pkg-config}:
|
2014-06-07 23:08:57 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation {
|
2020-02-08 22:15:00 +00:00
|
|
|
pname = "fceux-unstable";
|
|
|
|
version = "2020-01-29";
|
2014-06-07 23:08:57 +01:00
|
|
|
|
2020-02-08 22:15:00 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "TASVideos";
|
|
|
|
repo = "fceux";
|
|
|
|
rev = "fb8d46d9697cb24b0ebe79d84eedf282f69ab337";
|
|
|
|
sha256 = "0gpz411dzfwx9mr34yi4zb1hphd5hha1nvwgzxki0sviwafca992";
|
2014-06-07 23:08:57 +01:00
|
|
|
};
|
|
|
|
|
2021-01-17 02:30:45 +00:00
|
|
|
nativeBuildInputs = [ pkg-config scons ];
|
2014-06-07 23:08:57 +01:00
|
|
|
buildInputs = [
|
2018-11-12 02:52:07 +00:00
|
|
|
zlib SDL lua5_1
|
2014-06-07 23:08:57 +01:00
|
|
|
];
|
|
|
|
|
2018-11-12 02:52:07 +00:00
|
|
|
sconsFlags = "OPENGL=false GTK=false CREATE_AVI=false LOGO=false";
|
|
|
|
prefixKey = "--prefix=";
|
2014-06-07 23:08:57 +01:00
|
|
|
|
|
|
|
# sed allows scons to find libraries in nix.
|
|
|
|
# mkdir is a hack to make scons succeed. It still doesn't
|
|
|
|
# actually put the files in there due to a bug in the SConstruct file.
|
|
|
|
# OPENGL doesn't work because fceux dlopens the library.
|
2018-11-12 02:52:07 +00:00
|
|
|
preBuild = ''
|
2014-06-07 23:08:57 +01:00
|
|
|
sed -e 's/env *= *Environment *.*/&; env['"'"'ENV'"'"']=os.environ;/' -i SConstruct
|
|
|
|
export CC="gcc"
|
|
|
|
export CXX="g++"
|
|
|
|
mkdir -p "$out" "$out/share/applications" "$out/share/pixmaps"
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "A Nintendo Entertainment System (NES) Emulator";
|
2021-01-15 13:21:58 +00:00
|
|
|
license = lib.licenses.gpl2;
|
|
|
|
maintainers = [ lib.maintainers.scubed2 ];
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "http://www.fceux.com/";
|
2021-01-15 13:21:58 +00:00
|
|
|
platforms = lib.platforms.linux;
|
2014-06-07 23:08:57 +01:00
|
|
|
};
|
|
|
|
}
|