Reintroduce licenseAccepted option

This commit is contained in:
Sander van der Burg
2018-12-05 21:37:13 +01:00
parent b99ac1c904
commit 3bfd3e73bf
3 changed files with 11 additions and 3 deletions

View File

@@ -1,4 +1,4 @@
{stdenv, fetchurl, requireFile, makeWrapper, unzip, autoPatchelfHook, pkgs, pkgs_i686}:
{stdenv, fetchurl, requireFile, makeWrapper, unzip, autoPatchelfHook, pkgs, pkgs_i686, licenseAccepted ? false}:
{ toolsVersion ? "25.2.5"
, platformToolsVersion ? "28.0.1"
@@ -20,6 +20,13 @@
, includeExtras ? []
}:
if !licenseAccepted then throw ''
You must accept the Android Software Development Kit License Agreement at
https://developer.android.com/studio/terms
by setting nixpkgs config option 'android_sdk.accept_license = true;'
''
else assert licenseAccepted;
let
inherit (pkgs) stdenv fetchurl makeWrapper unzip;