sdkmanager in third_party/android_sdk doesn't pick up other installed packages |
||
Issue descriptionRunning third_party/android_sdk/public/tools/bin/sdkmanager --list gives: Installed packages:=====================] 100% Computing updates... Path | Version | Description | Location ------- | ------- | ------- | ------- tools | 26.1.1 | Android SDK Tools | tools/ Running third_party/android_tools/sdk/tools/bin/sdkmanager --list gives: Installed packages:=====================] 100% Computing updates... Path | Version | Description | Location ------- | ------- | ------- | ------- build-tools;27.0.3 | 27.0.3 | Android SDK Build-Tools 27.0.3 | build-tools/27.0.3/ emulator | 26.0.3 | Android Emulator | emulator/ extras;android;m2repository | 41.0.0 | Android Support Repository, rev 41 | extras/android/m2repository/ extras;android;support | 23.2.1 | Android Support Library, rev 23.2.1 | extras/android/support/ extras;google;gcm | 3.0.0 | Google Cloud Messaging for Android Library, rev 3 | extras/google/gcm/ platform-tools | 27.0.1 | Android SDK Platform-Tools 27.0.1 | platform-tools/ platforms;android-27 | 1 | Android SDK Platform 27 | platforms/android-27/ sources;android-25 | 1 | Sources for Android 25 | sources/android-25/ tools | 26.1.1 | Android SDK Tools | tools/
,
May 11 2018
This is because the sdk packages in third_party/android_sdk are all symlinks of cipd packages. Instead of finding the current path, the sdkmanager binary would find the real package path as SDK root, e.g. '.cipd/pkgs/33/_current/tools', which only contains the tools package. One option is to use the command '--sdk_root' to indicate the specific SDK root 'android_sdk' like `third_party/android_sdk/public/tools/bin/sdkmanager --list --sdk_root=third_party/android_sdk/public`: Installed packages:=====================] 100% Computing updates... Path | Version | Description | Location ------- | ------- | ------- | ------- build-tools;27.0.3 | 27.0.3 | Android SDK Build-Tools 27.0.3 | build-tools/27.0.3/ emulator | 27.1.12 | Android Emulator | emulator/ extras;android;m2repository | 47.0.0 | Android Support Repository | extras/android/m2repository/ extras;android;support | 23.2.1 | Android Support Library, rev 23.2.1 | extras/android/support/ extras;google;gcm | 3.0.0 | Google Cloud Messaging for Android Library, rev 3 | extras/google/gcm/ platform-tools | 27.0.1 | Android SDK Platform-Tools | platform-tools/ platforms;android-27 | 1 | Android SDK Platform 27 | platforms/android-27/ tools | 26.1.1 | Android SDK Tools | tools/
,
May 14 2018
Nice! I think that is a sufficiently good workaround. For posterity, use this instead: third_party/android_sdk/public/tools/bin/sdkmanager --list --sdk_root=third_party/android_sdk/public |
||
►
Sign in to add a comment |
||
Comment 1 by tandrii@chromium.org
, May 10 2018