在 CentOS 7 中安装 Google V8,缺少一些文件

在 CentOS 7 中安装 Google V8,缺少一些文件

我正在跟进这些步骤在 CentOS 7 中编译 Google V8 以获取 v8js 扩展:

cd /tmp

git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
export PATH=`pwd`/depot_tools:"$PATH"

fetch v8
cd v8

make native library=shared -j2

chrpath -r '$ORIGIN' out/native/lib.target/libv8.so

sudo mkdir -p /tmp/v8-install/lib /tmp/v8-install/include
sudo cp out/native/lib.target/lib*.so /tmp/v8-install/lib/
sudo cp -R include/* /tmp/v8-install/include
echo -e "create /tmp/v8-install/lib/libv8_libplatform.a\naddlib out/native/obj.target/tools/gyp/libv8_libplatform.a\nsave\nend" | sudo ar -M

问题是make native library=shared缺少整个文件 /tools/gyp/libv8_libplatform.a,所以我卡在这一步

echo -e "create /tmp/v8-install/lib/libv8_libplatform.a\naddlib out/native/obj.target/tools/gyp/libv8_libplatform.a\nsave\nend" | sudo ar -M  <== no file found!

我试过了,但出现了一个新问题。目录中make release library=shared -j2没有。有人有在 CentOs 7 中安装 Google V8 的经验吗?你能找出问题所在吗?lib.target/libv8.soout/Release/

相关内容