Port build www/node fails on FreeBSD 10.3 c++ '-DNODE_ARCH="x64"' '-DNODE_PLATFORM="freebsd"' '-DNODE_WANT_INTERNALS=1' '-DV8_DEPRECATION_WARNINGS=1' '-DNODE_OPENSSL_SYSTEM_CERT_PATH=""' '-DHAVE_INSPECTOR=1' '-D__POSIX__' '-DHAVE_OPENSSL=1' '-DNODE_USE_V8_PLATFORM=1' '-DNODE_HAVE_I18N_SUPPORT=1' '-DHTTP_PARSER_STRICT=0' '-DNGHTTP2_STATICLIB' -I../src -I../tools/msvs/genfiles -I/usr/ports/www/node/work/node-v9.3.0/out/Release/obj/gen -I/usr/ports/www/node/work/node-v9.3.0/out/Release/obj/gen/include -I../deps/openssl/openssl/include -I../deps/v8/include -I../deps/http_parser -I../deps/nghttp2/lib/includes -pthread -Wall -Wextra -Wno-unused-parameter -m64 -D_LIBCPP_TRIVIAL_PAIR_COPY_CTOR=1 -O3 -fno-omit-frame-pointer -fno-rtti -fno-exceptions -std=gnu++0x -MMD -MF /usr/ports/www/node/work/node-v9.3.0/out/Release/.deps//usr/ports/www/node/work/node-v9.3.0/out/Release/obj.target/node/src/connect_wrap.o.d.raw -isystem /usr/local/include -O2 -pipe -fstack-protector -isystem /usr/local/include -fno-strict-aliasing -isystem /usr/local/include -c -o /usr/ports/www/node/work/node-v9.3.0/out/Release/obj.target/node/src/connect_wrap.o ../src/connect_wrap.cc c++ '-DNODE_ARCH="x64"' '-DNODE_PLATFORM="freebsd"' '-DNODE_WANT_INTERNALS=1' '-DV8_DEPRECATION_WARNINGS=1' '-DNODE_OPENSSL_SYSTEM_CERT_PATH=""' '-DHAVE_INSPECTOR=1' '-D__POSIX__' '-DHAVE_OPENSSL=1' '-DNODE_USE_V8_PLATFORM=1' '-DNODE_HAVE_I18N_SUPPORT=1' '-DHTTP_PARSER_STRICT=0' '-DNGHTTP2_STATICLIB' -I../src -I../tools/msvs/genfiles -I/usr/ports/www/node/work/node-v9.3.0/out/Release/obj/gen -I/usr/ports/www/node/work/node-v9.3.0/out/Release/obj/gen/include -I../deps/openssl/openssl/include -I../deps/v8/include -I../deps/http_parser -I../deps/nghttp2/lib/includes -pthread -Wall -Wextra -Wno-unused-parameter -m64 -D_LIBCPP_TRIVIAL_PAIR_COPY_CTOR=1 -O3 -fno-omit-frame-pointer -fno-rtti -fno-exceptions -std=gnu++0x -MMD -MF /usr/ports/www/node/work/node-v9.3.0/out/Release/.deps//usr/ports/www/node/work/node-v9.3.0/out/Release/obj.target/node/src/env.o.d.raw -isystem /usr/local/include -O2 -pipe -fstack-protector -isystem /usr/local/include -fno-strict-aliasing -isystem /usr/local/include -c -o /usr/ports/www/node/work/node-v9.3.0/out/Release/obj.target/node/src/env.o ../src/env.cc ../src/env.cc:180:11: error: use of undeclared identifier 'uv_os_getpid' uv_os_getpid()); ^ 1 error generated. gmake[3]: *** [node.target.mk:176: /usr/ports/www/node/work/node-v9.3.0/out/Release/obj.target/node/src/env.o] Error 1 rm 9e73802ceac03f55261bd8c9820cfb4878c84ce4.intermediate gmake[2]: *** [Makefile:87: node] Error 2 gmake[2]: Leaving directory '/usr/ports/www/node/work/node-v9.3.0' ===> Compilation failed unexpectedly. Try to set MAKE_JOBS_UNSAFE=yes and rebuild before reporting the failure to the maintainer. *** Error code 1
It looks like you need upgrade libuv as well. The uv_os_getpid() function was added in libuv 1.18.0
Okay. But is necessary to explicitly add the request in LIB_DEPENDS + = ?
@Bradley Can you add >=1.18.0 to the existing libuv LIB_DEPENDS line so that users (and the build system) are informed of the minimum version requirement. Another user recently reported (via IRC) that the node/npm packages fail at runtime with the same error.
LIB_DEPENDS doesn't take version range like the other *_DEPENDS values. I think I may use explicit BUILD_DEPENDS and RUN_DEPENDS values with minimum versions instead.
10.3 is EOL. If there are issues with newer versions, please open a new PR. Close with overcome by events.