Skip to content

Instantly share code, notes, and snippets.

@nikki93
Created August 24, 2018 21:28
Show Gist options
  • Save nikki93/855094c9c225f20c9bfcf40747c85e19 to your computer and use it in GitHub Desktop.
Save nikki93/855094c9c225f20c9bfcf40747c85e19 to your computer and use it in GitHub Desktop.
with (import <nixpkgs> {});
let
pname = "ghost";
version = "0.0.1";
freetype = (import <nixos-unstable> {}).freetype;
libcef = (import <nixos-unstable> {}).libcef;
in
stdenv.mkDerivation rec {
name = "${pname}-${version}";
src = ../ghost;
nativeBuildInputs = [ cmake ];
buildInputs = [
SDL2 libGLU_combined openal luajit libdevil freetype physfs libmodplug mpg123
libogg libvorbis libtheora openssl libcef
];
preConfigure = ''
cd love
mkdir -p build
for i in ${libcef}/share/cef/*; do
ln -s $i build/
done
'';
installPhase = ''
mkdir -p $out/bin
cp love $out/bin/ghost
'';
meta = {
# TODO(nikki): Fill this in later!
#homepage = http://love2d.org;
#description = "A Lua-based 2D game engine/scripting language";
#license = stdenv.lib.licenses.zlib;
#platforms = stdenv.lib.platforms.linux;
#maintainers = [ stdenv.lib.maintainers.raskin ];
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment