-
-
Notifications
You must be signed in to change notification settings - Fork 372
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ANDROID_SDK_ROOT does not point to an Android SDK #1499
Comments
This is the specific error from
With the release of
So, with the new Briefcase release, the reason the SDK is rejected is made somewhat clearer now IMO. As for dealing with a user-specified SDK that doesn't contain the Command-line Tools....this is a bit messier. While the error suggests that version 9.0 is required, it can technically also make do with a version installed as "latest". However, it is required that one of these two versions of the Command-line Tools exists in an SDK to use it.....without those tools, Briefcase cannot ensure the SDK later contains the remaining parts of the SDK are installed (e.g. the emulator). During the development of #1397, we did consider bootstrapping the Command-line Tools in to a user-specified SDK by downloading a copy and using it to install the Command-line Tools in to the user's SDK but this was ultimately rejected. FWIW, this seems to be how Android Studio is able to use an arbitrary existing SDK without any Command-line Tools...since it brings its own tools along with itself. Given all this, unless we want to reconsider some of it, I'm not sure there's anything actionable necessarily. (meta: after pushing #1397, it never was clear to me what an arbitrary directory must contain to be considered an Android SDK. Google seems to have created a _very_ mushy definition of what this SDK is....and what one needs to contain to be considered one. The SDK more seems like a collection of independent scripts and tools that amassed together organically instead of with a plan in mind ahead of time.....although, now, the SDK Manager in Android Studio can help hide a lot of this since you can build an SDK by clicking a bunch of checkboxes.) |
I think I agree, unless we want to make one small tweak to make the failure mode explicit by changing:
to
|
Describe the bug
When you want briefcase to use an already installed Android SDK (on Windows), you can set the environment variable ANDROID_SDK_ROOT or ANDROID_HOME.
When running
briefcase create android
you might get the following warning:even though the environment variable does point to the correct folder. The reason for the warning message is that the Android Sdk does not include the command-line tools.
Steps to reproduce
briefcase create android
ANDROID_SDK_ROOT does not point to an Android SDK
Expected behavior
The error message should be more specific, e.g.
no command-line tools found under the folder {ANDROID_SDK_ROOT}
Screenshots
No response
Environment
Logs
Additional context
No response
The text was updated successfully, but these errors were encountered: