aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/android-sdk.rb
diff options
context:
space:
mode:
authorMax Howell2011-01-25 13:39:47 +0000
committerMax Howell2011-01-25 13:39:47 +0000
commitb5a918b4a4106ab2ebdd1130a6b0c6bc51a1b0c7 (patch)
tree0e6c8ae28cee630a125d611cd31972b16bbe148e /Library/Formula/android-sdk.rb
parent88557252a5f163d49654e06555e1c103432f3aa1 (diff)
downloadhomebrew-b5a918b4a4106ab2ebdd1130a6b0c6bc51a1b0c7.tar.bz2
Add adb to bin again
And I also discovered that the android SDK update tool is retarded, so added comments and caveats to document this.
Diffstat (limited to 'Library/Formula/android-sdk.rb')
-rw-r--r--Library/Formula/android-sdk.rb27
1 files changed, 24 insertions, 3 deletions
diff --git a/Library/Formula/android-sdk.rb b/Library/Formula/android-sdk.rb
index d0921c36e..e7fdb4aff 100644
--- a/Library/Formula/android-sdk.rb
+++ b/Library/Formula/android-sdk.rb
@@ -7,7 +7,9 @@ class AndroidSdk <Formula
version 'r8'
def self.var_dirs
- %w[platforms docs samples temp add-ons]
+ %w[platforms samples temp add-ons ]
+ # TODO docs, google-market_licensing and platform-tools
+ # See the long comment below for the associated problems
end
skip_clean var_dirs
@@ -32,11 +34,30 @@ class AndroidSdk <Formula
src.mkpath unless src.directory?
dst.make_relative_symlink src
end
+
+ (bin/:adb).write <<-EOS.undent
+ #!/bin/sh
+ ADB="#{prefix}/platform-tools/adb"
+ test -f "$ADB" && exec "$ADB" $@
+ echo Use the \\`android\\' tool to install adb.
+ EOS
end
def caveats; <<-EOS.undent
- We put the useful tools in the PATH. Like the `android` tool. You probably
- want to run that now.
+ Now run the `android' tool to install the actual SDK stuff.
+ You will have to install the platform-tools EVERY time this formula updates.
+ If you want to try and fix this then see the comment in this formula.
EOS
end
+
+ # The `android' tool insists on deleting /usr/local/Cellar/android-sdl/rx/platform-tools
+ # and then installing the new one. So it is impossible for us to redirect
+ # the SDK location to var so that the platform-tools don't have to be
+ # freshly installed EVERY FUCKING time the base SDK updates.
+ # My disgust at Google's ineptitude here knows NO bounds. I can only LOL.
+ # And I do LOL. A lot. In Google's general direction. I can't stop LOLing.
+ # In fact, I may have LOLd myself into insanity.
+
+ # Ideas: make android a script that calls the actual android tool, but after
+ # that tool exits it repairs the directory locations?
end