Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build failing with Node 10 and even in node 12 #869

Open
sriramHaven opened this issue Sep 18, 2019 · 3 comments
Open

Build failing with Node 10 and even in node 12 #869

sriramHaven opened this issue Sep 18, 2019 · 3 comments

Comments

@sriramHaven
Copy link

sriramHaven commented Sep 18, 2019

  • Node Version and npm version and tsc version: v10.13.0 and 6.10.3 and 3.6.3
  • Platform: Darwin mac19 18.7.0 Darwin Kernel Version 18.7.0: Tue Aug 20 16:57:14 PDT 2019; root:xnu-4903.271.2~2/RELEASE_X86_64 x86_64
  • Compiler: Apple LLVM version 10.0.1 (clang-1001.0.46.4)
    Target: x86_64-apple-darwin18.7.0
    Thread model: posix
    InstalledDir: /Library/Developer/CommandLineTools/usr/bin
  • Module: npm ci or npm install for my project . ( could be an issue in bunyan or dtrace which is not a direct dependency in my project )
  • Os version : 10.14.6 macOS Mojave
Verbose output (from npm or node-gyp):
machine: src_code$ npm install

> [email protected] install /Users/mm99468/SourceCode/cdm-founders/node_modules/dtrace-provider
> node-gyp rebuild || node suppress-error.js

  LD_LIBRARY_PATH=/Users/mm99468/SourceCode/cdm-founders/node_modules/dtrace-provider/build/Release/lib.host:/Users/mm99468/SourceCode/cdm-founders/node_modules/dtrace-provider/build/Release/lib.target:$LD_LIBRARY_PATH; export LD_LIBRARY_PATH; cd ../.; bash build.sh
+ buildUSDT
+ [[ -z '' ]]
+ [[ -z /Users/mm99468/SourceCode/cdm-founders ]]
+ unset MAKEFLAGS
++ node -e 'console.log(process.arch === '\''x64'\'' ? '\''x86_64'\'' : '\''i386'\'')'
+ export ARCH=x86_64
+ ARCH=x86_64
+ echo 'Building libusdt for x86_64'
Building libusdt for x86_64
+ [[ -z '' ]]
++ which gmake
+ MAKE=
+ [[ -z '' ]]
+ MAKE=make
+ make -C libusdt clean all
rm -f *.gch
rm -f *.o
rm -f libusdt.a
rm -f test_usdt
rm -f test_usdt32
rm -f test_usdt64
rm -f test_mem_usage
gcc -O2 -Wall -arch x86_64   -c -o usdt.o usdt.c
gcc -O2 -Wall -arch x86_64   -c -o usdt_dof_file.o usdt_dof_file.c
gcc -arch x86_64 -o usdt_tracepoints.o -c usdt_tracepoints_x86_64.s
gcc -O2 -Wall -arch x86_64   -c -o usdt_probe.o usdt_probe.c
gcc -O2 -Wall -arch x86_64   -c -o usdt_dof.o usdt_dof.c
gcc -O2 -Wall -arch x86_64   -c -o usdt_dof_sections.o usdt_dof_sections.c
rm -f libusdt.a
ar cru libusdt.a usdt.o usdt_dof_file.o usdt_tracepoints.o usdt_probe.o usdt_dof.o usdt_dof_sections.o
ranlib libusdt.a
+ LIBUSDT_STATUS=0
+ [[ 0 -ne 0 ]]
+ buildNDTP
+ [[ -z '' ]]
+ [[ -z /Users/mm99468/SourceCode/cdm-founders ]]
+ node-gyp rebuild -C src
  c++ '-DNODE_GYP_MODULE_NAME=DTraceProviderBindings' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_DARWIN_USE_64_BIT_INODE=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DBUILDING_NODE_EXTENSION' -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/src -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/deps/openssl/config -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/deps/openssl/openssl/include -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/deps/uv/include -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/deps/zlib -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/deps/v8/include -I../../libusdt -I../../../nan  -Os -gdwarf-2 -mmacosx-version-min=10.10 -arch x86_64 -Wall -Wendif-labels -W -Wno-unused-parameter -std=gnu++1y -stdlib=libc++ -fno-rtti -fno-exceptions -fno-strict-aliasing -MMD -MF ./Release/.deps/Release/obj.target/DTraceProviderBindings/dtrace_provider.o.d.raw   -c -o Release/obj.target/DTraceProviderBindings/dtrace_provider.o ../dtrace_provider.cc
In file included from ../dtrace_provider.cc:1:
In file included from ../dtrace_provider.h:1:
In file included from ../../../nan/nan.h:222:
In file included from ../../../nan/nan_converters.h:67:
../../../nan/nan_converters_43_inl.h:22:1: warning: 'ToBoolean' is deprecated: ToBoolean can never throw. Use Local version. [-Wdeprecated-declarations]
X(Boolean)
^
../../../nan/nan_converters_43_inl.h:18:12: note: expanded from macro 'X'
      val->To ## TYPE(isolate->GetCurrentContext())                            \
           ^
<scratch space>:208:1: note: expanded from here
ToBoolean
^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2536:3: note: 'ToBoolean' has been explicitly marked deprecated here
  V8_DEPRECATED("ToBoolean can never throw. Use Local version.",
  ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8config.h:311:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
In file included from ../dtrace_provider.cc:1:
In file included from ../dtrace_provider.h:1:
In file included from ../../../nan/nan.h:222:
In file included from ../../../nan/nan_converters.h:67:
../../../nan/nan_converters_43_inl.h:40:1: warning: 'BooleanValue' is deprecated: BooleanValue can never throw. Use Isolate version. [-Wdeprecated-declarations]
X(bool, Boolean)
^
../../../nan/nan_converters_43_inl.h:37:15: note: expanded from macro 'X'
  return val->NAME ## Value(isolate->GetCurrentContext());                     \
              ^
<scratch space>:215:1: note: expanded from here
BooleanValue
^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2574:3: note: 'BooleanValue' has been explicitly marked deprecated here
  V8_DEPRECATED("BooleanValue can never throw. Use Isolate version.",
  ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8config.h:311:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
In file included from ../dtrace_provider.cc:1:
In file included from ../dtrace_provider.h:1:
In file included from ../../../nan/nan.h:223:
In file included from ../../../nan/nan_new.h:189:
../../../nan/nan_implementation_12_inl.h:356:37: error: too few arguments to function call, expected 2, have 1
  return v8::StringObject::New(value).As<v8::StringObject>();
         ~~~~~~~~~~~~~~~~~~~~~      ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:5394:3: note: 'New' declared here
  static Local<Value> New(Isolate* isolate, Local<String> value);
  ^
In file included from ../dtrace_provider.cc:1:
In file included from ../dtrace_provider.h:1:
In file included from ../../../nan/nan.h:223:
In file included from ../../../nan/nan_new.h:189:
../../../nan/nan_implementation_12_inl.h:356:58: error: expected '(' for function-style cast or type construction
  return v8::StringObject::New(value).As<v8::StringObject>();
                                         ~~~~~~~~~~~~~~~~^
../../../nan/nan_implementation_12_inl.h:356:60: error: expected expression
  return v8::StringObject::New(value).As<v8::StringObject>();
                                                           ^
In file included from ../dtrace_provider.cc:1:
In file included from ../dtrace_provider.h:1:
In file included from ../../../nan/nan.h:2722:
../../../nan/nan_object_wrap.h:24:25: error: no member named 'IsNearDeath' in 'Nan::Persistent<v8::Object, v8::NonCopyablePersistentTraits<v8::Object> >'
    assert(persistent().IsNearDeath());
           ~~~~~~~~~~~~ ^
/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/assert.h:93:25: note: expanded from macro 'assert'
    (__builtin_expect(!(e), 0) ? __assert_rtn(__func__, __FILE__, __LINE__, #e) : (void)0)
                        ^
In file included from ../dtrace_provider.cc:1:
In file included from ../dtrace_provider.h:1:
In file included from ../../../nan/nan.h:2722:
../../../nan/nan_object_wrap.h:127:26: error: no member named 'IsNearDeath' in 'Nan::Persistent<v8::Object, v8::NonCopyablePersistentTraits<v8::Object> >'
    assert(wrap->handle_.IsNearDeath());
           ~~~~~~~~~~~~~ ^
/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/assert.h:93:25: note: expanded from macro 'assert'
    (__builtin_expect(!(e), 0) ? __assert_rtn(__func__, __FILE__, __LINE__, #e) : (void)0)
                        ^
../dtrace_provider.cc:35:85: error: too few arguments to function call, single argument 'context' was not specified
    target->Set(Nan::New<String>("DTraceProvider").ToLocalChecked(), t->GetFunction());
                                                                     ~~~~~~~~~~~~~~ ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:5961:3: note: 'GetFunction' declared here
  V8_WARN_UNUSED_RESULT MaybeLocal<Function> GetFunction(
  ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
../dtrace_provider.cc:52:37: error: no matching member function for call to 'ToString'
    String::Utf8Value name(info[0]->ToString());
                           ~~~~~~~~~^~~~~~~~
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2541:44: note: candidate function not viable: requires single argument 'context', but no arguments were
      provided
  V8_WARN_UNUSED_RESULT MaybeLocal<String> ToString(
                                           ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2557:31: note: candidate function not viable: requires single argument 'isolate', but no arguments were
      provided
                Local<String> ToString(Isolate* isolate) const);
                              ^
../dtrace_provider.cc:60:38: error: no matching member function for call to 'ToString'
      String::Utf8Value mod(info[1]->ToString());
                            ~~~~~~~~~^~~~~~~~
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2541:44: note: candidate function not viable: requires single argument 'context', but no arguments were
      provided
  V8_WARN_UNUSED_RESULT MaybeLocal<String> ToString(
                                           ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2557:31: note: candidate function not viable: requires single argument 'isolate', but no arguments were
      provided
                Local<String> ToString(Isolate* isolate) const);
                              ^
../dtrace_provider.cc:88:84: error: too few arguments to function call, single argument 'context' was not specified
        Nan::New<FunctionTemplate>(DTraceProbe::constructor_template)->GetFunction();
        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:5961:3: note: 'GetFunction' declared here
  V8_WARN_UNUSED_RESULT MaybeLocal<Function> GetFunction(
  ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
../dtrace_provider.cc:92:67: error: no matching member function for call to 'ToObject'
    DTraceProbe *probe = Nan::ObjectWrap::Unwrap<DTraceProbe>(pd->ToObject());
                                                              ~~~~^~~~~~~~
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2545:44: note: candidate function not viable: requires single argument 'context', but no arguments were
      provided
  V8_WARN_UNUSED_RESULT MaybeLocal<Object> ToObject(
                                           ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2559:31: note: candidate function not viable: requires single argument 'isolate', but no arguments were
      provided
                Local<Object> ToObject(Isolate* isolate) const);
                              ^
../dtrace_provider.cc:93:23: error: no matching member function for call to 'ToString'
    obj->Set(info[0]->ToString(), pd);
             ~~~~~~~~~^~~~~~~~
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2541:44: note: candidate function not viable: requires single argument 'context', but no arguments were
      provided
  V8_WARN_UNUSED_RESULT MaybeLocal<String> ToString(
                                           ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2557:31: note: candidate function not viable: requires single argument 'isolate', but no arguments were
      provided
                Local<String> ToString(Isolate* isolate) const);
                              ^
../dtrace_provider.cc:96:10: warning: 'ForceSet' is deprecated [-Wdeprecated-declarations]
    Nan::ForceSet(pd, Nan::New<String>("__prov__").ToLocalChecked(), obj,
         ^
../../../nan/nan_maybe_43_inl.h:130:1: note: 'ForceSet' has been explicitly marked deprecated here
NAN_DEPRECATED inline Maybe<bool> ForceSet(
^
../../../nan/nan.h:103:40: note: expanded from macro 'NAN_DEPRECATED'
# define NAN_DEPRECATED __attribute__((deprecated))
                                       ^
../dtrace_provider.cc:102:45: error: no matching member function for call to 'ToString'
        String::Utf8Value type(info[i + 1]->ToString());
                               ~~~~~~~~~~~~~^~~~~~~~
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2541:44: note: candidate function not viable: requires single argument 'context', but no arguments were
      provided
  V8_WARN_UNUSED_RESULT MaybeLocal<String> ToString(
                                           ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2557:31: note: candidate function not viable: requires single argument 'isolate', but no arguments were
      provided
                Local<String> ToString(Isolate* isolate) const);
                              ^
../dtrace_provider.cc:118:37: error: no matching member function for call to 'ToString'
    String::Utf8Value name(info[0]->ToString());
                           ~~~~~~~~~^~~~~~~~
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2541:44: note: candidate function not viable: requires single argument 'context', but no arguments were
      provided
  V8_WARN_UNUSED_RESULT MaybeLocal<String> ToString(
                                           ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2557:31: note: candidate function not viable: requires single argument 'isolate', but no arguments were
      provided
                Local<String> ToString(Isolate* isolate) const);
                              ^
../dtrace_provider.cc:140:19: error: no matching member function for call to 'Delete'
    provider_obj->Delete(name);
    ~~~~~~~~~~~~~~^~~~~~
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:3465:37: note: candidate function not viable: requires 2 arguments, but 1 was provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Delete(Local<Context> context,
                                    ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:3470:37: note: candidate function not viable: requires 2 arguments, but 1 was provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Delete(Local<Context> context,
                                    ^
3 warnings and 14 errors generated.
make[1]: *** [Release/obj.target/DTraceProviderBindings/dtrace_provider.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:196:23)
gyp ERR! stack     at ChildProcess.emit (events.js:209:13)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Darwin 18.7.0
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "-C" "src"
gyp ERR! cwd /Users/mm99468/SourceCode/cdm-founders/node_modules/dtrace-provider/src
gyp ERR! node -v v12.10.0
gyp ERR! node-gyp -v v5.0.3
gyp ERR! not ok
+ NODE_GYP_STATUS=1
+ [[ 1 -ne 0 ]]
+ fail 1
+ [[ -z '' ]]
+ [[ -z /Users/mm99468/SourceCode/cdm-founders ]]
+ [[ '' == \h\a\r\d ]]
+ exit 0
  touch Release/obj.target/ndtp.stamp
added 879 packages from 1151 contributors and audited 5367 packages in 12.108s
found 60 vulnerabilities (1 low, 59 high)
  run `npm audit fix` to fix them, or `npm audit` for details
MM99468M3:cdm-founders mm99468$ rm -rf node_modules/
MM99468M3:cdm-founders mm99468$ npm ci

> [email protected] install /Users/mm99468/SourceCode/cdm-founders/node_modules/dtrace-provider
> node-gyp rebuild || node suppress-error.js

gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | darwin | x64
gyp info find Python using Python version 2.7.10 found at "/usr/bin/python"
gyp info spawn /usr/bin/python
gyp info spawn args [
gyp info spawn args   '/usr/local/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py',
gyp info spawn args   'binding.gyp',
gyp info spawn args   '-f',
gyp info spawn args   'make',
gyp info spawn args   '-I',
gyp info spawn args   '/Users/mm99468/SourceCode/cdm-founders/node_modules/dtrace-provider/build/config.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/usr/local/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/common.gypi',
gyp info spawn args   '-Dlibrary=shared_library',
gyp info spawn args   '-Dvisibility=default',
gyp info spawn args   '-Dnode_root_dir=/Users/mm99468/Library/Caches/node-gyp/12.10.0',
gyp info spawn args   '-Dnode_gyp_dir=/usr/local/lib/node_modules/npm/node_modules/node-gyp',
gyp info spawn args   '-Dnode_lib_file=/Users/mm99468/Library/Caches/node-gyp/12.10.0/<(target_arch)/node.lib',
gyp info spawn args   '-Dmodule_root_dir=/Users/mm99468/SourceCode/cdm-founders/node_modules/dtrace-provider',
gyp info spawn args   '-Dnode_engine=v8',
gyp info spawn args   '--depth=.',
gyp info spawn args   '--no-parallel',
gyp info spawn args   '--generator-output',
gyp info spawn args   'build',
gyp info spawn args   '-Goutput_dir=.'
gyp info spawn args ]
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
  LD_LIBRARY_PATH=/Users/mm99468/SourceCode/cdm-founders/node_modules/dtrace-provider/build/Release/lib.host:/Users/mm99468/SourceCode/cdm-founders/node_modules/dtrace-provider/build/Release/lib.target:$LD_LIBRARY_PATH; export LD_LIBRARY_PATH; cd ../.; bash build.sh
+ buildUSDT
+ [[ -z '' ]]
+ [[ -z /Users/mm99468/SourceCode/cdm-founders ]]
+ unset MAKEFLAGS
++ node -e 'console.log(process.arch === '\''x64'\'' ? '\''x86_64'\'' : '\''i386'\'')'
+ export ARCH=x86_64
+ ARCH=x86_64
+ echo 'Building libusdt for x86_64'
Building libusdt for x86_64
+ [[ -z '' ]]
++ which gmake
+ MAKE=
+ [[ -z '' ]]
+ MAKE=make
+ make -C libusdt clean all
rm -f *.gch
rm -f *.o
rm -f libusdt.a
rm -f test_usdt
rm -f test_usdt32
rm -f test_usdt64
rm -f test_mem_usage
gcc -O2 -Wall -arch x86_64   -c -o usdt.o usdt.c
gcc -O2 -Wall -arch x86_64   -c -o usdt_dof_file.o usdt_dof_file.c
gcc -arch x86_64 -o usdt_tracepoints.o -c usdt_tracepoints_x86_64.s
gcc -O2 -Wall -arch x86_64   -c -o usdt_probe.o usdt_probe.c
gcc -O2 -Wall -arch x86_64   -c -o usdt_dof.o usdt_dof.c
gcc -O2 -Wall -arch x86_64   -c -o usdt_dof_sections.o usdt_dof_sections.c
rm -f libusdt.a
ar cru libusdt.a usdt.o usdt_dof_file.o usdt_tracepoints.o usdt_probe.o usdt_dof.o usdt_dof_sections.o
ranlib libusdt.a
+ LIBUSDT_STATUS=0
+ [[ 0 -ne 0 ]]
+ buildNDTP
+ [[ -z '' ]]
+ [[ -z /Users/mm99468/SourceCode/cdm-founders ]]
+ node-gyp rebuild -C src
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | darwin | x64
gyp info chdir src
gyp info find Python using Python version 2.7.10 found at "/usr/bin/python"
gyp info spawn /usr/bin/python
gyp info spawn args [
gyp info spawn args   '/usr/local/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py',
gyp info spawn args   'binding.gyp',
gyp info spawn args   '-f',
gyp info spawn args   'make',
gyp info spawn args   '-I',
gyp info spawn args   '/Users/mm99468/SourceCode/cdm-founders/node_modules/dtrace-provider/src/build/config.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/usr/local/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/common.gypi',
gyp info spawn args   '-Dlibrary=shared_library',
gyp info spawn args   '-Dvisibility=default',
gyp info spawn args   '-Dnode_root_dir=/Users/mm99468/Library/Caches/node-gyp/12.10.0',
gyp info spawn args   '-Dnode_gyp_dir=/usr/local/lib/node_modules/npm/node_modules/node-gyp',
gyp info spawn args   '-Dnode_lib_file=/Users/mm99468/Library/Caches/node-gyp/12.10.0/<(target_arch)/node.lib',
gyp info spawn args   '-Dmodule_root_dir=/Users/mm99468/SourceCode/cdm-founders/node_modules/dtrace-provider/src',
gyp info spawn args   '-Dnode_engine=v8',
gyp info spawn args   '--depth=.',
gyp info spawn args   '--no-parallel',
gyp info spawn args   '--generator-output',
gyp info spawn args   'build',
gyp info spawn args   '-Goutput_dir=.'
gyp info spawn args ]
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
  c++ '-DNODE_GYP_MODULE_NAME=DTraceProviderBindings' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_DARWIN_USE_64_BIT_INODE=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DBUILDING_NODE_EXTENSION' -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/src -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/deps/openssl/config -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/deps/openssl/openssl/include -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/deps/uv/include -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/deps/zlib -I/Users/mm99468/Library/Caches/node-gyp/12.10.0/deps/v8/include -I../../libusdt -I../../../nan  -Os -gdwarf-2 -mmacosx-version-min=10.10 -arch x86_64 -Wall -Wendif-labels -W -Wno-unused-parameter -std=gnu++1y -stdlib=libc++ -fno-rtti -fno-exceptions -fno-strict-aliasing -MMD -MF ./Release/.deps/Release/obj.target/DTraceProviderBindings/dtrace_provider.o.d.raw   -c -o Release/obj.target/DTraceProviderBindings/dtrace_provider.o ../dtrace_provider.cc
In file included from ../dtrace_provider.cc:1:
In file included from ../dtrace_provider.h:1:
In file included from ../../../nan/nan.h:222:
In file included from ../../../nan/nan_converters.h:67:
../../../nan/nan_converters_43_inl.h:22:1: warning: 'ToBoolean' is deprecated: ToBoolean can never throw. Use Local version. [-Wdeprecated-declarations]
X(Boolean)
^
../../../nan/nan_converters_43_inl.h:18:12: note: expanded from macro 'X'
      val->To ## TYPE(isolate->GetCurrentContext())                            \
           ^
<scratch space>:208:1: note: expanded from here
ToBoolean
^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2536:3: note: 'ToBoolean' has been explicitly marked deprecated here
  V8_DEPRECATED("ToBoolean can never throw. Use Local version.",
  ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8config.h:311:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
In file included from ../dtrace_provider.cc:1:
In file included from ../dtrace_provider.h:1:
In file included from ../../../nan/nan.h:222:
In file included from ../../../nan/nan_converters.h:67:
../../../nan/nan_converters_43_inl.h:40:1: warning: 'BooleanValue' is deprecated: BooleanValue can never throw. Use Isolate version. [-Wdeprecated-declarations]
X(bool, Boolean)
^
../../../nan/nan_converters_43_inl.h:37:15: note: expanded from macro 'X'
  return val->NAME ## Value(isolate->GetCurrentContext());                     \
              ^
<scratch space>:215:1: note: expanded from here
BooleanValue
^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2574:3: note: 'BooleanValue' has been explicitly marked deprecated here
  V8_DEPRECATED("BooleanValue can never throw. Use Isolate version.",
  ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8config.h:311:29: note: expanded from macro 'V8_DEPRECATED'
  declarator __attribute__((deprecated(message)))
                            ^
In file included from ../dtrace_provider.cc:1:
In file included from ../dtrace_provider.h:1:
In file included from ../../../nan/nan.h:223:
In file included from ../../../nan/nan_new.h:189:
../../../nan/nan_implementation_12_inl.h:356:37: error: too few arguments to function call, expected 2, have 1
  return v8::StringObject::New(value).As<v8::StringObject>();
         ~~~~~~~~~~~~~~~~~~~~~      ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:5394:3: note: 'New' declared here
  static Local<Value> New(Isolate* isolate, Local<String> value);
  ^
In file included from ../dtrace_provider.cc:1:
In file included from ../dtrace_provider.h:1:
In file included from ../../../nan/nan.h:223:
In file included from ../../../nan/nan_new.h:189:
../../../nan/nan_implementation_12_inl.h:356:58: error: expected '(' for function-style cast or type construction
  return v8::StringObject::New(value).As<v8::StringObject>();
                                         ~~~~~~~~~~~~~~~~^
../../../nan/nan_implementation_12_inl.h:356:60: error: expected expression
  return v8::StringObject::New(value).As<v8::StringObject>();
                                                           ^
In file included from ../dtrace_provider.cc:1:
In file included from ../dtrace_provider.h:1:
In file included from ../../../nan/nan.h:2722:
../../../nan/nan_object_wrap.h:24:25: error: no member named 'IsNearDeath' in 'Nan::Persistent<v8::Object, v8::NonCopyablePersistentTraits<v8::Object> >'
    assert(persistent().IsNearDeath());
           ~~~~~~~~~~~~ ^
/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/assert.h:93:25: note: expanded from macro 'assert'
    (__builtin_expect(!(e), 0) ? __assert_rtn(__func__, __FILE__, __LINE__, #e) : (void)0)
                        ^
In file included from ../dtrace_provider.cc:1:
In file included from ../dtrace_provider.h:1:
In file included from ../../../nan/nan.h:2722:
../../../nan/nan_object_wrap.h:127:26: error: no member named 'IsNearDeath' in 'Nan::Persistent<v8::Object, v8::NonCopyablePersistentTraits<v8::Object> >'
    assert(wrap->handle_.IsNearDeath());
           ~~~~~~~~~~~~~ ^
/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk/usr/include/assert.h:93:25: note: expanded from macro 'assert'
    (__builtin_expect(!(e), 0) ? __assert_rtn(__func__, __FILE__, __LINE__, #e) : (void)0)
                        ^
../dtrace_provider.cc:35:85: error: too few arguments to function call, single argument 'context' was not specified
    target->Set(Nan::New<String>("DTraceProvider").ToLocalChecked(), t->GetFunction());
                                                                     ~~~~~~~~~~~~~~ ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:5961:3: note: 'GetFunction' declared here
  V8_WARN_UNUSED_RESULT MaybeLocal<Function> GetFunction(
  ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
../dtrace_provider.cc:52:37: error: no matching member function for call to 'ToString'
    String::Utf8Value name(info[0]->ToString());
                           ~~~~~~~~~^~~~~~~~
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2541:44: note: candidate function not viable: requires single argument 'context', but no arguments were
      provided
  V8_WARN_UNUSED_RESULT MaybeLocal<String> ToString(
                                           ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2557:31: note: candidate function not viable: requires single argument 'isolate', but no arguments were
      provided
                Local<String> ToString(Isolate* isolate) const);
                              ^
../dtrace_provider.cc:60:38: error: no matching member function for call to 'ToString'
      String::Utf8Value mod(info[1]->ToString());
                            ~~~~~~~~~^~~~~~~~
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2541:44: note: candidate function not viable: requires single argument 'context', but no arguments were
      provided
  V8_WARN_UNUSED_RESULT MaybeLocal<String> ToString(
                                           ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2557:31: note: candidate function not viable: requires single argument 'isolate', but no arguments were
      provided
                Local<String> ToString(Isolate* isolate) const);
                              ^
../dtrace_provider.cc:88:84: error: too few arguments to function call, single argument 'context' was not specified
        Nan::New<FunctionTemplate>(DTraceProbe::constructor_template)->GetFunction();
        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:5961:3: note: 'GetFunction' declared here
  V8_WARN_UNUSED_RESULT MaybeLocal<Function> GetFunction(
  ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8config.h:351:31: note: expanded from macro 'V8_WARN_UNUSED_RESULT'
#define V8_WARN_UNUSED_RESULT __attribute__((warn_unused_result))
                              ^
../dtrace_provider.cc:92:67: error: no matching member function for call to 'ToObject'
    DTraceProbe *probe = Nan::ObjectWrap::Unwrap<DTraceProbe>(pd->ToObject());
                                                              ~~~~^~~~~~~~
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2545:44: note: candidate function not viable: requires single argument 'context', but no arguments were
      provided
  V8_WARN_UNUSED_RESULT MaybeLocal<Object> ToObject(
                                           ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2559:31: note: candidate function not viable: requires single argument 'isolate', but no arguments were
      provided
                Local<Object> ToObject(Isolate* isolate) const);
                              ^
../dtrace_provider.cc:93:23: error: no matching member function for call to 'ToString'
    obj->Set(info[0]->ToString(), pd);
             ~~~~~~~~~^~~~~~~~
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2541:44: note: candidate function not viable: requires single argument 'context', but no arguments were
      provided
  V8_WARN_UNUSED_RESULT MaybeLocal<String> ToString(
                                           ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2557:31: note: candidate function not viable: requires single argument 'isolate', but no arguments were
      provided
                Local<String> ToString(Isolate* isolate) const);
                              ^
../dtrace_provider.cc:96:10: warning: 'ForceSet' is deprecated [-Wdeprecated-declarations]
    Nan::ForceSet(pd, Nan::New<String>("__prov__").ToLocalChecked(), obj,
         ^
../../../nan/nan_maybe_43_inl.h:130:1: note: 'ForceSet' has been explicitly marked deprecated here
NAN_DEPRECATED inline Maybe<bool> ForceSet(
^
../../../nan/nan.h:103:40: note: expanded from macro 'NAN_DEPRECATED'
# define NAN_DEPRECATED __attribute__((deprecated))
                                       ^
../dtrace_provider.cc:102:45: error: no matching member function for call to 'ToString'
        String::Utf8Value type(info[i + 1]->ToString());
                               ~~~~~~~~~~~~~^~~~~~~~
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2541:44: note: candidate function not viable: requires single argument 'context', but no arguments were
      provided
  V8_WARN_UNUSED_RESULT MaybeLocal<String> ToString(
                                           ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2557:31: note: candidate function not viable: requires single argument 'isolate', but no arguments were
      provided
                Local<String> ToString(Isolate* isolate) const);
                              ^
../dtrace_provider.cc:118:37: error: no matching member function for call to 'ToString'
    String::Utf8Value name(info[0]->ToString());
                           ~~~~~~~~~^~~~~~~~
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2541:44: note: candidate function not viable: requires single argument 'context', but no arguments were
      provided
  V8_WARN_UNUSED_RESULT MaybeLocal<String> ToString(
                                           ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:2557:31: note: candidate function not viable: requires single argument 'isolate', but no arguments were
      provided
                Local<String> ToString(Isolate* isolate) const);
                              ^
../dtrace_provider.cc:140:19: error: no matching member function for call to 'Delete'
    provider_obj->Delete(name);
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:3465:37: note: candidate function not viable: requires 2 arguments, but 1 was provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Delete(Local<Context> context,
                                    ^
/Users/mm99468/Library/Caches/node-gyp/12.10.0/include/node/v8.h:3470:37: note: candidate function not viable: requires 2 arguments, but 1 was provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Delete(Local<Context> context,
                                    ^
3 warnings and 14 errors generated.
make[1]: *** [Release/obj.target/DTraceProviderBindings/dtrace_provider.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:196:23)
gyp ERR! stack     at ChildProcess.emit (events.js:209:13)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Darwin 18.7.0
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "-C" "src"
gyp ERR! cwd /Users/mm99468/SourceCode/cdm-founders/node_modules/dtrace-provider/src
gyp ERR! node -v v12.10.0
gyp ERR! node-gyp -v v5.0.3
gyp ERR! not ok
+ NODE_GYP_STATUS=1
+ [[ 1 -ne 0 ]]
+ fail 1
+ [[ -z '' ]]
+ [[ -z /Users/mm99468/SourceCode/cdm-founders ]]
+ [[ '' == \h\a\r\d ]]
+ exit 0
  touch Release/obj.target/ndtp.stamp
gyp info ok
added 879 packages in 7.924s

Build with this throws the following error

> [email protected] build:compile <path>
> tsc -p tsconfig.json

error TS2688: Cannot find type definition file for 'bunyan'.

error TS2688: Cannot find type definition file for 'restify'.

error TS2688: Cannot find type definition file for 'spdy'.

error TS2688: Cannot find type definition file for 'validator'.

Package-lock of secondary and tertiary dependency of dtrace-provider and NAN respectively looks like

      "version": "0.8.7",
      "resolved": "https://registry.npmjs.org/dtrace-provider/-/dtrace-provider-0.8.7.tgz",
      "integrity": "sha1-3JObTT4GIM/gwc2APQ0tftBP/QQ=",
      "optional": true,
      "requires": {
        "nan": "^2.10.0"
      }
    },
"nan": {
      "version": "2.12.1",
      "resolved": "https://registry.npmjs.org/nan/-/nan-2.12.1.tgz",
      "integrity": "sha512-JY7V6lRkStKcKTvHO5NVSQRv+RV+FIL5pvDoLiAtSL9pKlC5x9PKQcZDsq7m4FO4d57mkhC6Z+QhAh3Jdk5JFw==",
      "optional": true
    },
@sriramHaven sriramHaven changed the title Build failing with Node 12 , Node 10 etc.. Build failing with Node 10 and even in node 12 Sep 18, 2019
@Flarna
Copy link
Member

Flarna commented Sep 18, 2019

Looks to me like a too old version of NAN (2.12.1) is used. Could you try with latest?

@lovell
Copy link
Contributor

lovell commented Oct 9, 2019

Cross-posted at nodejs/node-gyp#1877 and chrisa/node-dtrace-provider#128

@sriramHaven Please don't open the same issue across multiple repos at the same time as this can and does waste the time of volunteer maintainers. It's usually best to start with the module/repo you have a question about, in this example dtrace-provider, then only ask in upstream dependencies if/when the maintainer(s) of that repo request that you do so.

@cclauss
Copy link
Contributor

cclauss commented Sep 29, 2023

Can this issue be closed-as-ignored?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants