【问题标题】:HaxeDevelop with hxml doesn't target the platform带有 hxml 的 HaxeDevelop 不针对平台
【发布时间】:2017-04-15 18:48:42
【问题描述】:

我的 build.hxml 文件如下所示:

-main Main -cp src -js bin/index.js

我在 Main 类中使用 js.Browser。当我尝试使用 F8 构建它时,FlashDevelop 给了我“你不能访问 js 包,而目标是交叉”。我实际上看到它试图运行:

Running process: bla-bla-bla -target "js" ... cmd: cmd /c haxe build.hxml haxe -cp src -main Main

所以它从 hxml 中删除 -js 参数,然后构建失败。如何解决?

【问题讨论】:

  • 什么是确切的项目配置(项目属性的输出和构建选项卡)?
  • 输出:平台为hxml,编译目标为Application,配置文件-build.hxml,测试项目-Web Server。当我将平台切换到 hxml 并尝试构建时,FlashDevelop 自动将预构建命令行设置为“cmd /c haxe $(OutputFile)”,构建后命令行为空。我使用 FlashDevelop 5.2.0.3。
  • 啊,你可能不得不选择“自定义构建”作为编译目标。
  • 成功了!谢谢!

标签: haxe flashdevelop


【解决方案1】:

在项目属性中,选择“Custom Build”作为编译目标。

The reason is that the hxml target uses a custom build command (Build tab) and when the Application compilation target is selected, FD will tr​​y to compile it a second time with an incorrect configuration.这确实是 FD 中的错误 - 在 Github 上提出问题?

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2018-08-03
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多