$ PATH在OSX中找不到Android命令

时间:2014-02-13 17:51:42

标签: android macos cordova path osx-mavericks

我正在尝试构建一个phonegap应用程序,但在安装Android SDK之后,我无法构建应用程序,因为在我的$ PATH中找不到android命令。

错误:

$ phonegap build android:

[phonegap] detecting Android SDK environment...
[phonegap] using the local environment
[phonegap] compiling Android...
   [error] An error occurred while building the android project.The command "android" failed. Make sure you have the latest Android SDK installed, and the "android" command (inside the tools/ folder) is added to your path.

$ echo $ PATH:

/opt/local/bin:/opt/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/opt/X11/bin:/usr/local/git/bin:/Development/adt-bundle/sdk/platform-tools:/Development/adt-bundle/sdk/tools:/Development/adt-bundle/sdk/build-tools:[/Development/adt-bundle/eclipse/plugins/org.apache.ant_1.8.3.v201301120609]/bin

我当前的.bash_profile

export PATH=${PATH}:/Development/adt-bundle/sdk/platform-tools
export PATH=${PATH}:/Development/adt-bundle/sdk/tools
export PATH=${PATH}:/Development/adt-bundle/sdk/build-tools
##
# Your previous /Users/macness/.bash_profile file was backed up as /Users/macness/.bash_profile.macports-saved_2014-02-12_at_20:16:11
##

# MacPorts Installer addition on 2014-02-12_at_20:16:11: adding an appropriate PATH variable for use with MacPorts.
export PATH=/opt/local/bin:/opt/local/sbin:$PATH
# Finished adapting your PATH environment variable for use with MacPorts.

export ANT_HOME="[/Development/adt-bundle/eclipse/plugins/org.apache.ant_1.8.3.v201301120609]" 
export PATH=$PATH:$ANT_HOME/bin

0 个答案:

没有答案