NetBeans Android插件出错

Kes*_*han 3 android netbeans netbeans-plugins netbeans-6.9

我目前正在开发Android应用程序,我正在使用Netbeans 6.9.1和nbandroid 1.0 beta.我已经安装了Android SDK并配置了所有内容,但是当我创建一个简单的项目并尝试构建它时会出错

Creating output directories if needed...
Created dir: C:\Documents and Settings\KeSoLK\My Documents\NetBeansProjects\AndroidApplication2\bin
Created dir: C:\Documents and Settings\KeSoLK\My Documents\NetBeansProjects\AndroidApplication2\gen
Created dir: C:\Documents and Settings\KeSoLK\My Documents\NetBeansProjects\AndroidApplication2\bin\classes
Compiling aidl files into Java classes...
Compiling RenderScript files into Java classes and RenderScript bytecode...
Generating R.java / Manifest.java from the resources...
compile:
C:\Documents and Settings\KeSoLK\My Documents\Android\android-sdk-windows\tools\ant\main_rules.xml:384: warning: 'includeantruntime' was not set, defaulting to build.sysclasspath=last; set to false for repeatable builds
Compiling 2 source files to C:\Documents and Settings\KeSoLK\My Documents\NetBeansProjects\AndroidApplication2\bin\classes
Converting compiled files and external libraries into C:\Documents and Settings\KeSoLK\My Documents\NetBeansProjects\AndroidApplication2\bin\classes.dex...
=C:\Documents was unexpected at this time.
C:\Documents and Settings\KeSoLK\My Documents\Android\android-sdk-windows\tools\ant\main_rules.xml:472: The following error occurred while executing this line:
C:\Documents and Settings\KeSoLK\My Documents\Android\android-sdk-windows\tools\ant\main_rules.xml:203: apply returned: 255
BUILD FAILED (total time: 1 second)
Run Code Online (Sandbox Code Playgroud)

可能是什么问题?以及如何解决它.

谢谢 !!

Mat*_*ndy 5

刚遇到同样的问题.它似乎与ant尝试使用参数启动dex.bat时路径中的空格有关:

<exec executable="${dx}" failonerror="true">
            <arg value="--dex"/>
            <arg value="--output=${basedir}/${intermediate.dex}"/>
            <arg value="--positions=lines"/>
            <arg path="${build.classes.dir}"/>
</exec>
Run Code Online (Sandbox Code Playgroud)

如果或包含空格${basedir},项目将不会运行.${intermediate.dex}${build.classes.dir}

批处理文件的参数必须用"..."封装.但是当ant启动批处理文件时如何做到这一点?

我的快速解决方法是将我的netbeans android项目(不是所有项目)的文件夹移动到不包含空格的路径.