【问题标题】:ios:createIPA gradle task fails with error in HfsCompressor.compressNativeios:createIPA gradle 任务因 HfsCompressor.compressNative 错误而失败
【发布时间】:2016-07-22 11:14:46
【问题描述】:

从命令行使用 ./gradlew ios:createIPA 构建 iOS 的 libGDX 游戏时,有时会收到以下错误:

...
:ios_lite:createIPA
RoboVM has detected that you are running on a slow HDD. Please consider mounting a RAM disk.
To create a 2GB RAM disk, run this in your terminal:
SIZE=2048 ; diskutil erasevolume HFS+ 'RoboVM RAM Disk' `hdiutil attach -nomount ram://$((SIZE * 2048))`
See http://docs.robovm.com/ for more info
RoboVM has detected that you are running on a slow HDD. Please consider mounting a RAM disk.
To create a 2GB RAM disk, run this in your terminal:
SIZE=2048 ; diskutil erasevolume HFS+ 'RoboVM RAM Disk' `hdiutil attach -nomount ram://$((SIZE * 2048))`
See http://docs.robovm.com/ for more info
:ios_lite:createIPA FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':ios_lite:createIPA'.
> org.robovm.compiler.util.io.HfsCompressor.compressNative(Ljava/lang/String;[BI)Z

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED

--info--debug 提供更多输出,但没有更多有用信息,--stacktrace 仅显示 Gradle 中的内部堆栈跟踪。

使用 Gradle 2.2、OS X 10.11.5、JVM 1.8.0_74、RoboVM 1.12.0。

是什么导致了这个错误,我该如何解决?

【问题讨论】:

    标签: ios libgdx robovm


    【解决方案1】:

    我仍然不知道是什么原因造成的(欢迎在这方面提供更好的答案),但我找到了一种解决方法:重新启动 Gradle 守护程序。在构建之前,只需运行:

    $ ./gradlew --stop
    

    守护程序将自动重新启动以进行下一次构建。到目前为止,这个解决方法已经可靠地为我修复了错误。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2020-03-06
      • 1970-01-01
      • 1970-01-01
      • 2016-01-19
      • 2015-05-10
      相关资源
      最近更新 更多