crystax-ndk: migrate to cask (#11811)

This commit is contained in:
Yurii Kolesnykov 2017-04-19 08:39:36 +03:00 committed by ilovezfs
parent 4075bb9b82
commit f0e28dfc05
2 changed files with 1 additions and 52 deletions

View file

@ -1,52 +0,0 @@
class CrystaxNdk < Formula
desc "Drop-in replacement for Google's Android NDK"
homepage "https://www.crystax.net/android/ndk"
version "10.3.1"
revision 1
if MacOS.prefer_64_bit?
url "https://www.crystax.net/download/crystax-ndk-#{version}-darwin-x86_64.tar.xz"
sha256 "6469c37e8fa107db51f9ada26fe3e27fddf3d6c3c51272a783fed36b110550ef"
else
url "https://www.crystax.net/download/crystax-ndk-#{version}-darwin-x86.tar.xz"
sha256 "a59218c0bfc477f0ef2dbd345f21cca4fb1f183b4e154ff7724ea0f6df8a7855"
end
bottle :unneeded
def install
bin.mkpath
prefix.install Dir["*"]
# Create a dummy script to launch the ndk apps
ndk_exec = prefix+"ndk-exec.sh"
ndk_exec.write <<-EOS.undent
#!/bin/sh
BASENAME=`basename $0`
EXEC="#{prefix}/$BASENAME"
test -e "$EXEC" && exec "$EXEC" "$@"
EOS
ndk_exec.chmod 0755
%w[ndk-build ndk-gdb ndk-stack ndk-depends ndk-which].each { |app| bin.install_symlink ndk_exec => app }
end
def caveats; <<-EOS.undent
We agreed to the CrystaX NDK License Agreement for you by downloading the NDK.
If this is unacceptable you should uninstall.
License information at:
https://www.crystax.net/android/ndk#license
For more documentation on CrystaX NDK, please check:
#{homepage}
EOS
end
test do
system "#{bin}/ndk-build", "--version"
system "#{bin}/ndk-gdb", "--help"
system "#{bin}/ndk-depends", "--help"
end
end

View file

@ -14,6 +14,7 @@
"cfitsio": "homebrew/science",
"cloudfoundry-cli": "pivotal/tap",
"cmucl": "caskroom/cask",
"crystax-ndk": "caskroom/cask",
"corelocationcli": "caskroom/cask",
"dart": "dart-lang/dart",
"datamash": "homebrew/science",