【问题标题】:building boost with emscripten on windows在 Windows 上使用 emscripten 构建提升
【发布时间】:2021-04-24 16:57:30
【问题描述】:

我正在尝试在 Windows 上使用 emscripten 构建提升。特别是,我正在尝试使用https://stackoverflow.com/a/47751199/5969590 中建议的 emscripten 工具集。但是,这会为我产生以下错误:

C:\dev\emsdk\python\3.9.2-1_64bit\python.exe: can't open file 'c:\dev\boost_1_76_0\emcc.py': [Errno 2] No such file or directory

boost 工具链中的某处尝试使用 python 调用 emcc.py,但由于传递了错误的模块路径而失败(c:\dev\boost_1_76_0\ 中没有 emcc.py)。

  • 我通过执行emsdk_env.bat 确保路径环境变量设置正确。手动运行emcc.bat(在内部运行emcc.py)会按预期执行编译器。
  • 我在emcc.bat 中插入了一些调试打印输出,从中我得知 boost 工具链没有使用该文件。似乎它试图直接使用 python 和emcc.py。这似乎是事情崩溃的地方。

非常感谢任何帮助或提示。

最好, 大卫

【问题讨论】:

    标签: windows boost build webassembly emscripten


    【解决方案1】:

    问题与此有关:What is the reason for batch file path referenced with %~dp0 sometimes changes on changing directory?

    我通过破解 emcc.bat 以使用 emcc.py 文件的硬编码路径解决了这个问题。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2020-05-29
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多