edge icon indicating copy to clipboard operation
edge copied to clipboard

Cannot build with node 10.0.0

Open frankcchen opened this issue 6 years ago • 6 comments

Was trying to build on windows. When I ran $ tools\buildall.bat, it raise this error:

C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V110\Microsoft.Cpp.Platform.targets(44,5): error MSB8020: The builds tools for v140 (Platform Toolset = 'v140') cannot be foun d. To build using the v140 build tools, either click the Project menu or right-click the solution, and then select "Update VC++ Projects...". Install v140 to build using the v1 40 build tools. [C:\Users\changch\repos\NodeBolt\node_modules\edge\build\edge_nativeclr.vcxproj]

Any idea how to solve this? Thanks!

frankcchen avatar Oct 25 '18 16:10 frankcchen

Make sure the correct version of msbuild is on your PATH (e.g. C:\Program Files (x86)\MSBuild\14.0\Bin) Easy option: run build from Developer Command Prompt for VS2015.

Mind you, this project seems to use deprecated node functions and doesn't build for current versions. You could contribute to this project by updating those errors, maybe look at the popular forks for inspiration (or simply use one of those instead).

BenHormann-Intergen avatar Oct 29 '18 21:10 BenHormann-Intergen

I also trying to build edge for node.js 10.0.0. And I have a lot of compiled errors from msbuild. For the nodejs 8.2.1 I have compiled successfully. But I want to use a newer version of nodejs. There is a v8config.h in the source code. I don't see other config file for new nodejs versions. Is it possible to compile the current state of code(master branch) for node.js 10.0.0?

Alexcei88 avatar Nov 11 '18 18:11 Alexcei88

There are at least two problems:

  1. the newer Google V8 versions need Visual Studio 2017 to build you need to install the new version and change "--msvs_version=2015" to "--msvs_version=2017" in tools/build.bat

  2. there is a build error with Visual Studio 2017: 'Task': ambiguous symbol You need to replace many (but not all!) instances of "Task" by "System::Threading::Tasks::Task" in the src directory

I also needed to install "nan", but that might be an issue with my local Node.js installation.

After these changes it compiled using Node 8.14.0. With Node 10 you might get additional issues. Use the command "tools\build.bat release 8.14.0" to compile it for a specific Node.js version.

I have uploaded the changes to my branch https://github.com/nospam2000/edge/tree/fixCompile_Node8_14_0/tools but haven't done more than compiling it, yet.

nospam2000 avatar Dec 17 '18 19:12 nospam2000

I can now compile my branch with Node.js 10.14.2. The 47 tests which don't compile 'cs' code succeeded, the other tests failed because 'edge-cs' is not installed.

nospam2000 avatar Dec 18 '18 18:12 nospam2000

Alternatively you can use https://github.com/agracio/edge-js that has support for all Node.js versions. It also includes a number of fixes that are not present in this project.

agracio avatar Dec 18 '18 18:12 agracio

Alternatively you can use https://github.com/agracio/edge-js that has support for all Node.js versions. It also includes a number of fixes that are not present in this project.

Thanks for the hint! I was completely lost between the other 579 forks of this project.

nospam2000 avatar Dec 18 '18 18:12 nospam2000