Conversation
def install | ||
File.rename "Mac/adb_Mac", "Mac/adb" | ||
File.rename "Mac/fastboot_Mac", "Mac/fastboot" | ||
bin.install "Mac/adb", "Mac/fastboot" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can rename a file in one step the install method:
bin.install 'Mac/abd_mac' => 'adb'
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The android-sdk
formula provides an adb
binary, so installing this will conflict. Presumably someone doing Android development will have the SDK installed, so this will always conflict. What's the story here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the feedback and review, I've updated the pull request accordingly.
About the rationale: adb and fastboot are two tools very widely used to flash (fastboot) and debug (adb) AOS-based devices; they're indeed part of the AOS SDK (which is a huge package).
What you may often want is just "flash" a device using fastboot with a blob and connect to it with adb; installing the whole AOS SDK for this whould be a major overkill.
Providing a package only for adb/fastboot is a pretty popular approach on many other platforms.
Looks like this is a prebuilt binary, is there a way to build from source? |
This isn't a bottle, fyi. Bottles are made with |
This Formula allows to install the adb and fastboot binaries alone for device flashing and debugging without using the whole AOS SDK.
What is the source of these files? Are they copied from the SDK itself originally? Potentially we could add an option to the android-sdk formula that only installs these two tools, rather than source copies of them from here. |
The Google Code project "adb-fastboot-install" is not related to myself but I've been using it for months when I have to set up adb and fastboot without wasting time and energies. The eventual idea of adding an option to the android-sdk Formula is certainly ok but wouldn't solve the issue of downloading hundreds of megabytes for only two simple tools that are not even 300 KB together. |
Basically I'm uncomfortable with trusting a 3rd party copy of the official tools, even though they are likely safe. But since I no longer do any Android development, I'll let another maintainer chime in here. |
I think requiring the |
Well, I sympathize and share your concern but in this case there are IMHO two only choices: providing a smaller package (not necessarily this one) or just... do nothing and leave the whole > 400MiB android-sdk package to whoever needs these tools. :) Having something like the android-tools-adb and android-tools-fastboot official packages currently available on Ubuntu and Debian would be pretty handy for brew users, though. My 2c. Obviously it's up to you guys to have the final word to keep brew supercool.:) |
Willing to package in Homebrew if we use the debian tarball http://packages.debian.org/sid/android-tools-fastboot (if it can be used). We should also name it the same as debian. Does debian rename the binaries on install? |
@michelangelo Exaggerrating doesn't help you; the package is 74M and 97M downloaded. I think this would be good in tap instead (or leave it open and see if there is more demand). |
@MikeMcQuaid "Exaggerating doesn't help you": what kind of way to respond is that?!! And to be totally clear: the latest AOS Tools package (that includes the SDK) for OS X (x86_64) is 409M. The Formula for android-sdk currently available does indeed involve a package of smaller size (because it includes only the SDK, as the name suggests) but yet significally bigger than 300KiB. 78M >> 300K, without "exaggerating". |
The official package http://dl-ssl.google.com/android/repository/platform-tools_r19.0.1-macosx.zip is also a pack of prebuilt binaries (adb and fastboot). It is only 1.1M. Compared with a 70+MB package of android-sdk, I feel it would be helpful to add the formula (but use the official url instead). |
@licheng Can you make a pull request? |
@MikeMcQuaid ok, i'll make a new pull request later. |
This commit adds a new Formula to easily install adb and fastboot for AOS device management.