From 76f32d9b41b7c6cc4c4d5e0bfeb5af8fbd2b1661 Mon Sep 17 00:00:00 2001 From: James Kay Date: Wed, 28 Mar 2018 12:43:07 +0100 Subject: [PATCH] godot: add a dev output containing the gdnative headers --- pkgs/development/tools/godot/default.nix | 26 +++++++++++++----------- 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/pkgs/development/tools/godot/default.nix b/pkgs/development/tools/godot/default.nix index 89cc7eb1bfee..88ea499d28cf 100644 --- a/pkgs/development/tools/godot/default.nix +++ b/pkgs/development/tools/godot/default.nix @@ -34,27 +34,29 @@ in stdenv.mkDerivation rec { enableParallelBuilding = true; buildPhase = '' - scons platform=x11 prefix=$out -j $NIX_BUILD_CORES \ + scons target=release_debug platform=x11 prefix=$out -j $NIX_BUILD_CORES \ ${lib.concatStringsSep " " (lib.mapAttrsToList (k: v: "${k}=${builtins.toJSON v}") options)} ''; + outputs = [ "out" "dev" "man" ]; + installPhase = '' - mkdir -p $out/bin - cp bin/godot.x11.tools.* $out/bin/godot + mkdir -p "$out/bin" + cp bin/godot.* $out/bin/godot - mkdir -p "$out/share/applications" + mkdir "$dev" + cp -r modules/gdnative/include $dev + + mkdir -p "$man/share/man/man6" + cp misc/dist/linux/godot.6 "$man/share/man/man6/" + + mkdir -p "$out"/share/{applications,icons/hicolor/scalable/apps} cp misc/dist/linux/godot.desktop "$out/share/applications/" - substituteInPlace "$out/share/applications/godot.desktop" \ - --replace "Exec=godot" \ - "Exec=$out/bin/godot" - - mkdir -p "$out/share/icons/hicolor/scalable/apps/" cp icon.svg "$out/share/icons/hicolor/scalable/apps/godot.svg" cp icon.png "$out/share/icons/godot.png" - - mkdir -p "$out/share/man/man6" - cp misc/dist/linux/godot.6 "$out/share/man/man6/" + substituteInPlace "$out/share/applications/godot.desktop" \ + --replace "Exec=godot" "Exec=$out/bin/godot" ''; meta = {