0

我只是想从命令提示符运行一个示例应用程序,该应用程序位于 cordova 库中。

当我尝试构建或运行应用程序时,出现以下错误。

我也更改了 project.properties 文件中的 webworks 路径。

E:\Software\BB 7\BB7_sample_app\example>ant blackberry build
Buildfile: E:\Software\BB 7\BB7_sample_app\example\build.xml

blackberry:

build:

generate-cod-name:
     [echo] Generated name: example.cod

clean:
   [delete] Deleting directory E:\Software\BB 7\BB7_sample_app\example\build

package-app:
    [mkdir] Created dir: E:\Software\BB 7\BB7_sample_app\example\build\widget
     [copy] Copying 22 files to E:\Software\BB 7\BB7_sample_app\example\build\widget
      [zip] Building zip: E:\Software\BB 7\BB7_sample_app\example\build\example.zip

build:
     [exec] [INFO]                      Parsing command line options
     [exec] [INFO]                      Parsing bbwp.properties
     [exec] [INFO]                      Validating application archive
     [exec] [INFO]                      Parsing config.xml
     [exec] [INFO]                      Populating application source
     [exec] [INFO]                      Compiling BlackBerry WebWorks application
     [exec] I/O Error: Cannot run program "C:\Program": CreateProcess error=2, The system cannot find the file specified
     [exec] [ERROR]                     RAPC exception occurred

BUILD SUCCESSFUL
Total time: 15 seconds

E:\Software\BB 7\BB7_sample_app\example>ant blackberry load-simulator
Buildfile: E:\Software\BB 7\BB7_sample_app\example\build.xml

blackberry:

load-simulator:

generate-cod-name:
     [echo] Generated name: example.cod

clean:
   [delete] Deleting directory E:\Software\BB 7\BB7_sample_app\example\build

package-app:
    [mkdir] Created dir: E:\Software\BB 7\BB7_sample_app\example\build\widget
     [copy] Copying 22 files to E:\Software\BB 7\BB7_sample_app\example\build\widget
      [zip] Building zip: E:\Software\BB 7\BB7_sample_app\example\build\example.zip

build:
     [exec] [INFO]                      Parsing command line options
     [exec] [INFO]                      Parsing bbwp.properties
     [exec] [INFO]                      Validating application archive
     [exec] [INFO]                      Parsing config.xml
     [exec] [INFO]                      Populating application source
     [exec] [INFO]                      Compiling BlackBerry WebWorks application
     [exec] I/O Error: Cannot run program "C:\Program": CreateProcess error=2, The system cannot find the file specified
     [exec] [ERROR]                     RAPC exception occurred

load-simulator:
     [echo] Simulator directory=C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks SDK 2.3.1.5\simpack\7.0.0.318
     [echo] Simulator directory=C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks SDK 2.3.1.5\simpack\7.0.0.318
     [echo] Simulator executable=C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks SDK 2.3.1.5\simpack\7.0.0.318/9930.bat
     [echo] Closing all running simulators...
     [exec] No sessions currently running.
     [exec] Result: 1
     [echo] MDS directory=C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks SDK 2.3.1.5/mds

BUILD FAILED
E:\Software\BB 7\BB7_sample_app\example\build.xml:51: The following error occurred while executing this line:
E:\Software\BB 7\BB7_sample_app\example\blackberry.xml:153: E:\Software\BB 7\BB7_sample_app\example\build\StandardInstall does not exist.

Total time: 16 seconds
4

1 回答 1

0

通过将 java 从 1.6 升级到 1.7 解决了这个问题。

于 2013-10-15T11:15:58.033 回答