diff options
author | Ilya Kolpakov <ilya.kolpakov@gmail.com> | 2017-11-16 13:46:37 +0100 |
---|---|---|
committer | Ilya Kolpakov <ilya.kolpakov@gmail.com> | 2017-11-16 13:46:37 +0100 |
commit | 886770c6f0ea3ed43ac934e459efe3ba5f9879e2 (patch) | |
tree | 90542bc1f275608b3d206f84c89620842c06d574 /pkgs | |
parent | fc8fbab87fead3d42ba5849ab50decf2f35aafcf (diff) |
google-cloud-sdk: no dependence on gce by default (fixes #31369)
Diffstat (limited to 'pkgs')
-rw-r--r-- | pkgs/tools/admin/google-cloud-sdk/default.nix | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/pkgs/tools/admin/google-cloud-sdk/default.nix b/pkgs/tools/admin/google-cloud-sdk/default.nix index ee62b1b84f19c..6dec65892b0f8 100644 --- a/pkgs/tools/admin/google-cloud-sdk/default.nix +++ b/pkgs/tools/admin/google-cloud-sdk/default.nix @@ -1,8 +1,18 @@ -{ stdenv, lib, fetchurl, python, cffi, cryptography, pyopenssl, crcmod, google-compute-engine, makeWrapper }: +# Make sure that the "with-gce" flag is set when building `google-cloud-sdk` +# for GCE hosts. This flag prevents "google-compute-engine" from being a +# default dependency which is undesirable because this package is +# +# 1) available only on GNU/Linux (requires `systemd` in particular) +# 2) intended only for GCE guests (and is useless elsewhere) +# 3) used by `google-cloud-sdk` only on GCE guests +# + +{ stdenv, lib, fetchurl, makeWrapper, python, cffi, cryptography, pyopenssl, + crcmod, google-compute-engine, with-gce ? false }: -# other systems not supported yet let - pythonInputs = [ cffi cryptography pyopenssl crcmod google-compute-engine ]; + pythonInputs = [ cffi cryptography pyopenssl crcmod ] + ++ lib.optional (with-gce) google-compute-engine; pythonPath = lib.makeSearchPath python.sitePackages pythonInputs; baseUrl = "https://dl.google.com/dl/cloudsdk/channels/rapid/downloads"; |