如何在 Windows 下构建 SpiderMonkey? [英] How to build SpiderMonkey under Windows?
问题描述
我尝试在 Windows 下构建 SpiderMonkey.我遵循 https://wiki.mozilla.org/JavaScript:New_to_SpiderMonkey 下的文档>
不同的是,我使用当前的 VS 15.9.11 而不是旧的 15.8.
如果我尝试在 Mozilla 构建 shell 中调用 configure
然后它找不到 c 编译器:
Winuser@Winuser/c/workspace-cpp/spidermonkey/js/src/build_DBG.OBJ$ ../configure --enable-debug --disable-optimize在 virtualenv 中重新执行检查 vcs 源结帐... hg检查外壳... C:/mozilla-build/msys/bin/sh.exe检查主机系统类型... x86_64-pc-mingw32检查目标系统类型... x86_64-pc-mingw32检查 Python 3... C:/mozilla-build//python3/python3.exe (3.6.5)检查汞... c:/mozilla-build/python/Scripts/hg.exe检查 Mercurial 版本... 4.5.3检查稀疏结帐...否检查是否交叉编译...没有检查 yasm... c:/mozilla-build/bin/yasm.exe检查 yasm 版本... 1.3.0检查目标 C 编译器...未找到调试:_cc:尝试 clang-cl调试:_cc:尝试 gcc调试:_cc:尝试叮当声错误:找不到目标 C 编译器
Mozilla 构建 shell 在哪里搜索 C 编译器?问题的原因是什么?3 种可能的 C 编译器中的哪一种来自 VS?
我(最终)完成了它的构建.我花了几天时间.
除了 mozillas spidermonkey 文档之外,我还使用了这些说明.
https://github.com/TheQwertiest/foo_spider_monkey_panel/wiki/Building-SpiderMonkey
我将列出一些需要记住的重要事项.
- 启动
x86 Native Tools Command Prompt for VS2017
- 在VS2017 cmd提示符
set MOZ_NO_RESET_PATH=1
- 在 VS2017 cmd 提示符下启动 minGW
mozilla-build/start-shell.bat
- 下载旧版 Autconf 并编译它http://www.linuxfromscratch.org/blfs/view/cvs/general/autoconf213.html
- 克隆 esr60 分支代码.我试过最新的代码,我试过最新发布的代码,但它必须在这个分支上编译才行.
所以不要强调这些要点,这些链接的说明可能会起作用.
I try to build SpiderMonkey under Windows. I follow the documentation under https://wiki.mozilla.org/JavaScript:New_to_SpiderMonkey
I have installed the prerequirement from https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Build_Instructions/Windows_Prerequisites
Differently I use the current VS 15.9.11 instead the old 15.8.
If I try to call configure
inside the Mozilla build shell then it can't find the c compiler:
Winuser@Winuser /c/workspace-cpp/spidermonkey/js/src/build_DBG.OBJ
$ ../configure --enable-debug --disable-optimize
Reexecuting in the virtualenv
checking for vcs source checkout... hg
checking for a shell... C:/mozilla-build/msys/bin/sh.exe
checking for host system type... x86_64-pc-mingw32
checking for target system type... x86_64-pc-mingw32
checking for Python 3... C:/mozilla-build//python3/python3.exe (3.6.5)
checking for hg... c:/mozilla-build/python/Scripts/hg.exe
checking for Mercurial version... 4.5.3
checking for sparse checkout... no
checking whether cross compiling... no
checking for yasm... c:/mozilla-build/bin/yasm.exe
checking yasm version... 1.3.0
checking for the target C compiler... not found
DEBUG: _cc: Trying clang-cl
DEBUG: _cc: Trying gcc
DEBUG: _cc: Trying clang
ERROR: Cannot find the target C compiler
Where is the Mozilla build shell searching for the C compiler? What can be the cause of the problem? Which of the 3 possible C compiler is coming from VS?
I (finaly) got it to build. It took me days.
I used these instructions in addition to mozillas spidermonkey documentation.
https://github.com/TheQwertiest/foo_spider_monkey_panel/wiki/Building-SpiderMonkey
I will list a few important things to remember.
- Launch
x86 Native Tools Command Prompt for VS2017
- in VS2017 cmd prompt
set MOZ_NO_RESET_PATH=1
- in VS2017 cmd prompt launch minGW
mozilla-build/start-shell.bat
- Download legacy Autconf and compile it http://www.linuxfromscratch.org/blfs/view/cvs/general/autoconf213.html
- clone esr60 branch code. I tried latest code , I tried latest released code, but it had to this branch until it compiled.
So emphasis no those points and these linked instructions may work.
这篇关于如何在 Windows 下构建 SpiderMonkey?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!