From ff647cab19dce77f7433ec7919424ff68b80de9b Mon Sep 17 00:00:00 2001 From: Florian Klink Date: Wed, 12 Jun 2019 17:34:17 +0200 Subject: [PATCH] google-cloud-sdk: use doBuild = false instead of hardcoding phases We don't want to unpack in installPhase either. --- pkgs/tools/admin/google-cloud-sdk/default.nix | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/pkgs/tools/admin/google-cloud-sdk/default.nix b/pkgs/tools/admin/google-cloud-sdk/default.nix index 3abd189d0f97..9099bfb242f4 100644 --- a/pkgs/tools/admin/google-cloud-sdk/default.nix +++ b/pkgs/tools/admin/google-cloud-sdk/default.nix @@ -36,16 +36,15 @@ in stdenv.mkDerivation rec { buildInputs = [ python makeWrapper ]; - phases = [ "installPhase" "fixupPhase" ]; + doBuild = false; + installPhase = '' - mkdir -p "$out" - tar -xzf "$src" -C "$out" google-cloud-sdk + mkdir -p $out/google-cloud-sdk + cp -R * .install $out/google-cloud-sdk/ - mkdir $out/google-cloud-sdk/lib/surface/alpha + mkdir -p $out/google-cloud-sdk/lib/surface/{alpha,beta} cp ${./alpha__init__.py} $out/google-cloud-sdk/lib/surface/alpha/__init__.py - - mkdir $out/google-cloud-sdk/lib/surface/beta cp ${./beta__init__.py} $out/google-cloud-sdk/lib/surface/beta/__init__.py # create wrappers with correct env @@ -68,8 +67,8 @@ in stdenv.mkDerivation rec { disable_update_check = true" >> $out/google-cloud-sdk/properties # setup bash completion - mkdir -p "$out/etc/bash_completion.d/" - mv "$out/google-cloud-sdk/completion.bash.inc" "$out/etc/bash_completion.d/gcloud.inc" + mkdir -p $out/etc/bash_completion.d + mv $out/google-cloud-sdk/completion.bash.inc $out/etc/bash_completion.d/gcloud.inc # This directory contains compiled mac binaries. We used crcmod from # nixpkgs instead.