@@ -1,6 +1,6 @@
11{ fetchFromGitHub, stdenv, pkgconfig, ncurses, lua, SDL2, SDL2_image, SDL2_ttf,
22SDL2_mixer, freetype, gettext, CoreFoundation, Cocoa,
3−tiles ? true }:
3+tiles ? true, debug ? false }:
44
55stdenv.mkDerivation rec {
66 version = "2018-07-15";
@@ -31,7 +31,6 @@ stdenv.mkDerivation rec {
3131 makeFlags = with stdenv.lib; [
3232 "PREFIX=$(out)"
3333 "LUA=1"
34− "RELEASE=1"
3534 "USE_HOME_DIR=1"
3635 "LANGUAGES=all"
3736 "VERSION=git-${version}-${substring 0 8 src.rev}"
@@ -41,6 +40,8 @@ stdenv.mkDerivation rec {
4140 ] ++ optionals stdenv.isDarwin [
4241 "NATIVE=osx"
4342 "CLANG=1"
43+ ] ++ optionals (! debug) [
44+ "RELEASE=1"
4445 ];
4546
4647 postInstall = with stdenv.lib; optionalString (tiles && !stdenv.isDarwin) ''
@@ -64,6 +65,8 @@ stdenv.mkDerivation rec {
6465 # make: *** [Makefile:687: obj/tiles/weather_data.o] Error 1
6566 enableParallelBuilding = false;
6667
68+ dontStrip = debug;
69+
6770 meta = with stdenv.lib; {
6871 description = "A free, post apocalyptic, zombie infested rogue-like";
6972 longDescription = ''