android-tools icon indicating copy to clipboard operation
android-tools copied to clipboard

Native Windows support?

Open meator opened this issue 7 months ago • 3 comments

Is this project compatible with Windows? If not, are you willing to accept patches/pull requests providing such support?

I wish to bundle a version of adb with my open source program. I cannot use the official downloads in https://developer.android.com/tools/releases/platform-tools, because its license is pretty restrictive:

[...]

3. SDK License from Google

[...] 3.4 You may not use the SDK for any purpose not expressly permitted by the License Agreement. Except to the extent required by applicable third party licenses, you may not copy (except for backup purposes), modify, adapt, redistribute, decompile, reverse engineer, disassemble, or create derivative works of the SDK or any part of the SDK. 3.5 Use, reproduction and distribution of components of the SDK licensed under an open source software license are governed solely by the terms of that open source software license and not the License Agreement. [...]

I am not 100% sure whether 3.4 applies to adb.exe bundled in https://developer.android.com/tools/releases/platform-tools#downloads, but I wanted to explore alternatives. One such alternative is building adb manually, making it licensed under Apache-2.0.

As you sure know, using android-tools' native build system Soong isn't the easiest task, so this project seems to be the best choice.

I may be willing to implement Windows support (if such change would be accepted), but from a brief look at the current build system, that might not be the simplest task.

meator avatar May 18 '25 09:05 meator

Windows binary can be used from here https://packages.msys2.org/base/mingw-w64-android-tools

Biswa96 avatar May 18 '25 11:05 Biswa96

@Biswa96 Thanks for the suggestion, but the executables in https://packages.msys2.org/base/mingw-w64-android-tools seem to have a lot of MSYS2 dependencies. I cannot use this package standalone and I cannot require my users to install MSYS2.

Finding a way to build adb.exe statically would be ideal for me. I'll examine MSYS2's modifications of android-tools' build system further.

meator avatar May 28 '25 19:05 meator

I cannot use this package standalone and I cannot require my users to install MSYS2.

This project does not statically link libraries either.

Biswa96 avatar May 28 '25 20:05 Biswa96