Skip to content

build: fix ninja build failure

Rodrigo Muino Tomonari requested to merge github/fork/danbev/ninja-build into master

When working on commit 6a09a69e ("build: enable cctest to use generated objects") I did not take into account building with ninja:

$ ./configure
$ tools/gyp_node.py -f ninja
$ ninja -C out/Release
$ ln -fs out/Release/node node

When ninja generated the ninja build files, src files that are relative to the src directory will be named with a dot instead of a path separator, for example:

out/Release/obj/src/node/node.o

would instead become:

out/Release/obj/src/node.node.o

This commit adds an additional variable for the typ of object separator used for this case.

Also, the LIBS specified in the 'libraries' section are not being included in the --start-group --end-group section which means that these libraries will not be searched causing issue with linkers where the order matters.

Fixes: https://github.com/nodejs/node/issues/12448

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
Affected core subsystem(s)

build

Merge request reports

Loading