0

我在 Win7 上使用 Ti Studio,当我通过 USB 插入我的 Android 并使用“Android 设备”运行时,我的项目构建和工作。

但是,当我尝试构建它以进行分发时,我得到:

[ERROR] Program launch failed. Unable to locate Java VM. Please set JAVA_HOME environment variable.

我查看了描述类似问题的这个线程,并验证了 JAVA_HOME 已设置:

+>echo %JAVA_HOME%
C:\Program Files\Java\jdk1.6.0_29

此外,在 Ti Studio 中,我已验证 Preferences->Studio->Platforms->Android 已将“Android SDK Home”设置为安装 Android SDK 的路径。

谁能指导我我还需要做些什么来解决这个问题?

谢谢!

ANAND 更新

+>javac -version
javac 1.6.0_29

+>java -version
java version "1.7.0_01"
Java(TM) SE Runtime Environment (build 1.7.0_01-b08)
Java HotSpot(TM) 64-Bit Server VM (build 21.1-b02, mixed mode)
4

2 回答 2

1

Did you read System Requirements?

From Documentation:

For Windows, the 32-bit version of Java JDK is required regardless of whether Titanium is running on a 32-bit or 64-bit system.

Try to install additional 32bit version of Java (without removing the 64bit) and set the system variable.

You may refer this answer.

Hope it helped you

于 2013-11-13T04:53:38.490 回答
1

配置这里提到的环境变量 ,JDK必须是32位

于 2013-11-13T10:24:44.093 回答