bitcoinjs / tiny-secp256k1

A tiny secp256k1 native/JS wrapper

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Warnings on install

ekkis opened this issue · comments

installing on OSX 10.14.6 (Mojave) I get the following warnings. The "unused function" warnings I guess are just a matter of cleaning up the code but the integer comparisons I would think are of concern. I'm guessing that's a platform dependent thing. is there some way to tweak the meaning of "int" to "unsigned long"? this should get cleaned up no?

~/dev $ npm i bitcoinjs-lib

tiny-secp256k1@1.1.3 install /Users/ekkis/dev/node_modules/tiny-secp256k1
npm run build || echo "secp256k1 bindings compilation fail. Pure JS implementation will be used."

tiny-secp256k1@1.1.3 build /Users/ekkis/dev/node_modules/tiny-secp256k1
node-gyp rebuild

CXX(target) Release/obj.target/secp256k1/native/addon.o
../native/addon.cpp:240:2: warning: ignoring return value of function declared with 'warn_unused_result'
attribute [-Wunused-result]
secp256k1_ec_privkey_negate(context, tweak_negated); // returns 1 always
^~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~
../native/addon.cpp:80:21: warning: comparison of integers of different signs: 'int' and 'unsigned long'
[-Wsign-compare]
if (info.Length() <= index) return __isPointCompressed(p) ? SECP256K1_EC_COMPRESSED : S...
~~~~~~~~~~~~~ ^ ~~~~~
../native/addon.cpp:142:21: note: in instantiation of function template specialization '(anonymous
namespace)::assumeCompression<2, Nan::FunctionCallbackInfov8::Value, v8::Localv8::Object >' requested
here
const auto flags = assumeCompression<2>(info, pA);
^
../native/addon.cpp:80:21: warning: comparison of integers of different signs: 'int' and 'unsigned long'
[-Wsign-compare]
if (info.Length() <= index) return __isPointCompressed(p) ? SECP256K1_EC_COMPRESSED : S...
~~~~~~~~~~~~~ ^ ~~~~~
../native/addon.cpp:174:21: note: in instantiation of function template specialization '(anonymous
namespace)::assumeCompression<1, Nan::FunctionCallbackInfov8::Value, v8::Localv8::Object >' requested
here
const auto flags = assumeCompression<1>(info, p);
^
../native/addon.cpp:87:21: warning: comparison of integers of different signs: 'int' and 'unsigned long'
[-Wsign-compare]
if (info.Length() <= index) return SECP256K1_EC_COMPRESSED;
~~~~~~~~~~~~~ ^ ~~~~~
../native/addon.cpp:189:21: note: in instantiation of function template specialization '(anonymous
namespace)::assumeCompression<1, Nan::FunctionCallbackInfov8::Value >' requested here
const auto flags = assumeCompression<1>(info);
^
../native/addon.cpp:21:32: warning: unused variable 'ZERO' [-Wunused-const-variable]
const std::array<uint8_t, 32> ZERO = {};
^
5 warnings generated.
CC(target) Release/obj.target/secp256k1/native/secp256k1/src/secp256k1.o
In file included from ../native/secp256k1/src/secp256k1.c:13:
../native/secp256k1/src/group_impl.h:686:12: warning: unused function 'secp256k1_gej_has_quad_y_var'
[-Wunused-function]
static int secp256k1_gej_has_quad_y_var(const secp256k1_gej *a) {
^
../native/secp256k1/src/group_impl.h:113:13: warning: unused function 'secp256k1_ge_set_gej_var'
[-Wunused-function]
static void secp256k1_ge_set_gej_var(secp256k1_ge *r, secp256k1_gej *a) {
^
../native/secp256k1/src/group_impl.h:267:12: warning: unused function 'secp256k1_gej_is_valid_var'
[-Wunused-function]
static int secp256k1_gej_is_valid_var(const secp256k1_gej *a) {
^
In file included from ../native/secp256k1/src/secp256k1.c:15:
../native/secp256k1/src/ecmult_const_impl.h:123:13: warning: unused function 'secp256k1_ecmult_const'
[-Wunused-function]
static void secp256k1_ecmult_const(secp256k1_gej *r, const secp256k1_ge *a, const secp256k1_scalar *scalar) {
^
4 warnings generated.
SOLINK_MODULE(target) Release/secp256k1.node
npm WARN proxy@1.0.0 No repository field.

  • bitcoinjs-lib@5.1.6
    added 36 packages from 47 contributors and audited 328 packages in 8.87s
    found 0 vulnerabilities
  • secp256k1_gej_has_quad_y_var used in test/benchmark
  • secp256k1_ge_set_gej_var used in test/recovery module
  • secp256k1_gej_is_valid_var used in test
  • secp256k1_ecmult_const used in test/ecdh module

What is really unclear, why this warnings generated while they disabled in gyp file: https://github.com/bitcoinjs/tiny-secp256k1/blob/v1.1.3/binding.gyp#L32

It looks like this is now throwing errors. Happening with Node v13.11.0 (locally) and Node 13.1.0 (Travis).

> tiny-secp256k1@1.1.3 build /Users/lemoustachiste/work/cert-verifier-js/node_modules/tiny-secp256k1
> node-gyp rebuild

  CXX(target) Release/obj.target/secp256k1/native/addon.o
../native/addon.cpp:240:2: warning: ignoring return value of function declared with 'warn_unused_result' attribute [-Wunused-result]
        secp256k1_ec_privkey_negate(context, tweak_negated); // returns 1 always
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~
../native/addon.cpp:320:34: error: no viable conversion from 'v8::Local<v8::Context>' to 'v8::Isolate *'
                strict = info[3]->BooleanValue(Nan::GetCurrentContext()).FromJust();
                                               ^~~~~~~~~~~~~~~~~~~~~~~~
/Users/lemoustachiste/Library/Caches/node-gyp/13.11.0/include/node/v8.h:2771:30: note: passing argument to parameter 'isolate' here
  bool BooleanValue(Isolate* isolate) const;
                             ^
../native/addon.cpp:82:36: error: no viable conversion from 'v8::Local<v8::Context>' to 'v8::Isolate *'
                return info[index]->BooleanValue(Nan::GetCurrentContext()).FromJust() ? SECP256K1_EC_COMPRESSED : SECP256K1_EC_UNCOMPRESSED;
                                                 ^~~~~~~~~~~~~~~~~~~~~~~~
../native/addon.cpp:142:21: note: in instantiation of function template specialization '(anonymous namespace)::assumeCompression<2, Nan::FunctionCallbackInfo<v8::Value>, v8::Local<v8::Object> >' requested
      here
        const auto flags = assumeCompression<2>(info, pA);
                           ^
/Users/lemoustachiste/Library/Caches/node-gyp/13.11.0/include/node/v8.h:2771:30: note: passing argument to parameter 'isolate' here
  bool BooleanValue(Isolate* isolate) const;
                             ^
../native/addon.cpp:80:21: warning: comparison of integers of different signs: 'int' and 'unsigned long' [-Wsign-compare]
                if (info.Length() <= index) return __isPointCompressed(p) ? SECP256K1_EC_COMPRESSED : SECP256K1_EC_UNCOMPRESSED;
                    ~~~~~~~~~~~~~ ^  ~~~~~
../native/addon.cpp:82:36: error: no viable conversion from 'v8::Local<v8::Context>' to 'v8::Isolate *'
                return info[index]->BooleanValue(Nan::GetCurrentContext()).FromJust() ? SECP256K1_EC_COMPRESSED : SECP256K1_EC_UNCOMPRESSED;
                                                 ^~~~~~~~~~~~~~~~~~~~~~~~
../native/addon.cpp:174:21: note: in instantiation of function template specialization '(anonymous namespace)::assumeCompression<1, Nan::FunctionCallbackInfo<v8::Value>, v8::Local<v8::Object> >' requested
      here
        const auto flags = assumeCompression<1>(info, p);
                           ^
/Users/lemoustachiste/Library/Caches/node-gyp/13.11.0/include/node/v8.h:2771:30: note: passing argument to parameter 'isolate' here
  bool BooleanValue(Isolate* isolate) const;
                             ^
../native/addon.cpp:80:21: warning: comparison of integers of different signs: 'int' and 'unsigned long' [-Wsign-compare]
                if (info.Length() <= index) return __isPointCompressed(p) ? SECP256K1_EC_COMPRESSED : SECP256K1_EC_UNCOMPRESSED;
                    ~~~~~~~~~~~~~ ^  ~~~~~
../native/addon.cpp:89:36: error: no viable conversion from 'v8::Local<v8::Context>' to 'v8::Isolate *'
                return info[index]->BooleanValue(Nan::GetCurrentContext()).FromJust() ? SECP256K1_EC_COMPRESSED : SECP256K1_EC_UNCOMPRESSED;
                                                 ^~~~~~~~~~~~~~~~~~~~~~~~
../native/addon.cpp:189:21: note: in instantiation of function template specialization '(anonymous namespace)::assumeCompression<1, Nan::FunctionCallbackInfo<v8::Value> >' requested here
        const auto flags = assumeCompression<1>(info);
                           ^
/Users/lemoustachiste/Library/Caches/node-gyp/13.11.0/include/node/v8.h:2771:30: note: passing argument to parameter 'isolate' here
  bool BooleanValue(Isolate* isolate) const;
                             ^
../native/addon.cpp:87:21: warning: comparison of integers of different signs: 'int' and 'unsigned long' [-Wsign-compare]
                if (info.Length() <= index) return SECP256K1_EC_COMPRESSED;
                    ~~~~~~~~~~~~~ ^  ~~~~~
4 warnings and 4 errors generated.
make: *** [Release/obj.target/secp256k1/native/addon.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/Users/lemoustachiste/.nvm/versions/node/v13.11.0/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:315:20)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:275:12)
gyp ERR! System Darwin 18.2.0
gyp ERR! command "/Users/lemoustachiste/.nvm/versions/node/v13.11.0/bin/node" "/Users/lemoustachiste/.nvm/versions/node/v13.11.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/lemoustachiste/work/cert-verifier-js/node_modules/tiny-secp256k1
gyp ERR! node -v v13.11.0
gyp ERR! node-gyp -v v5.0.7
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! tiny-secp256k1@1.1.3 build: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the tiny-secp256k1@1.1.3 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/lemoustachiste/.npm/_logs/2020-03-18T14_59_09_752Z-debug.log
secp256k1 bindings compilation fail. Pure JS implementation will be used.

I can avoid this error using Node 11.

commented

Node v10.18.1 also have the same😕

Node v10.18.1 also have the same

I have verified that it successfully installs on v10.18.1

Terminal Output
junderw ~
$ cd $(mktemp -d)
junderw /tmp/tmp.dZD2bhQsLU
$ npm init -y
Wrote to /tmp/tmp.dZD2bhQsLU/package.json:

{
  "name": "tmp.dZD2bhQsLU",
  "version": "1.0.0",
  "description": "",
  "main": "index.js",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1"
  },
  "keywords": [],
  "author": "",
  "license": "ISC"
}

junderw /tmp/tmp.dZD2bhQsLU
$ nvm install v10.18.1
Downloading and installing node v10.18.1...
Downloading https://nodejs.org/dist/v10.18.1/node-v10.18.1-linux-x64.tar.xz...
######################################################################### 100.0%
Computing checksum with sha256sum
Checksums matched!
Now using node v10.18.1 (npm v6.13.4)
junderw /tmp/tmp.dZD2bhQsLU
$ npm i tiny-secp256k1

> tiny-secp256k1@1.1.3 install /tmp/tmp.dZD2bhQsLU/node_modules/tiny-secp256k1
> npm run build || echo "secp256k1 bindings compilation fail. Pure JS implementation will be used."


> tiny-secp256k1@1.1.3 build /tmp/tmp.dZD2bhQsLU/node_modules/tiny-secp256k1
> node-gyp rebuild

make: ディレクトリ '/tmp/tmp.dZD2bhQsLU/node_modules/tiny-secp256k1/build' に入ります
  CXX(target) Release/obj.target/secp256k1/native/addon.o
../native/addon.cpp: In instantiation of ‘unsigned int {anonymous}::assumeCompression(const I&, const A&) [with long unsigned int index = 2; I = Nan::FunctionCallbackInfo<v8::Value>; A = v8::Local<v8::Object>]’:
../native/addon.cpp:142:50:   required from here
../native/addon.cpp:80:21: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
   if (info.Length() <= index) return __isPointCompressed(p) ? SECP256K1_EC_COMPRESSED : SECP256K1_EC_UNCOMPRESSED;
../native/addon.cpp: In instantiation of ‘unsigned int {anonymous}::assumeCompression(const I&, const A&) [with long unsigned int index = 1; I = Nan::FunctionCallbackInfo<v8::Value>; A = v8::Local<v8::Object>]’:
../native/addon.cpp:174:49:   required from here
../native/addon.cpp:80:21: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
../native/addon.cpp: In instantiation of ‘unsigned int {anonymous}::assumeCompression(const I&) [with long unsigned int index = 1; I = Nan::FunctionCallbackInfo<v8::Value>]’:
../native/addon.cpp:189:46:   required from here
../native/addon.cpp:87:21: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
   if (info.Length() <= index) return SECP256K1_EC_COMPRESSED;
../native/addon.cpp: In function ‘Nan::NAN_METHOD_RETURN_TYPE eccPrivateSub(Nan::NAN_METHOD_ARGS_TYPE)’:
../native/addon.cpp:240:29: warning: ignoring return value of ‘int secp256k1_ec_privkey_negate(const secp256k1_context*, unsigned char*)’, declared with attribute warn_unused_result [-Wunused-result]
  secp256k1_ec_privkey_negate(context, tweak_negated); // returns 1 always
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
  CC(target) Release/obj.target/secp256k1/native/secp256k1/src/secp256k1.o
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ec_pubkey_parse’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘pubkey’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:154:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(pubkey != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘input’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:156:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(input != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ec_pubkey_serialize’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘output’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:175:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(output != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘outputlen’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:171:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(outputlen != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘pubkey’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:177:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(pubkey != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ecdsa_signature_parse_der’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘sig’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:216:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(sig != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘input’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:217:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(input != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ecdsa_signature_parse_compact’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘sig’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:234:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(sig != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘input64’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:235:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(input64 != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ecdsa_signature_serialize_der’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘output’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:253:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(output != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘outputlen’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:254:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(outputlen != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘sig’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:255:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(sig != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ecdsa_signature_serialize_compact’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘output64’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:265:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(output64 != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘sig’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:266:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(sig != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ecdsa_signature_normalize’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘sigin’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:279:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(sigin != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ecdsa_verify’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘sig’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:300:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(sig != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘msg32’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:299:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(msg32 != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘pubkey’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:301:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(pubkey != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ecdsa_sign’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘signature’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:353:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(signature != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘msg32’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:352:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(msg32 != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘seckey’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:354:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(seckey != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ec_seckey_verify’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘seckey’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:396:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(seckey != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ec_pubkey_create’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘pubkey’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:411:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(pubkey != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘seckey’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:414:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(seckey != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ec_privkey_negate’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘seckey’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:430:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(seckey != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ec_pubkey_negate’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘pubkey’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:443:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(pubkey != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ec_privkey_tweak_add’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘seckey’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:460:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(seckey != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘tweak’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:461:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(tweak != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ec_pubkey_tweak_add’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘pubkey’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:484:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(pubkey != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘tweak’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:485:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(tweak != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ec_privkey_tweak_mul’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘seckey’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:507:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(seckey != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘tweak’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:508:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(tweak != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ec_pubkey_tweak_mul’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘pubkey’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:530:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(pubkey != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘tweak’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:531:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(tweak != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c: In function ‘secp256k1_ec_pubkey_combine’:
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘pubnonce’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:559:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(pubnonce != NULL);
     ^~~~~~~~~
../native/secp256k1/src/secp256k1.c:22:8: warning: nonnull argument ‘pubnonces’ compared to NULL [-Wnonnull-compare]
     if (EXPECT(!(cond), 0)) { \
        ^
../native/secp256k1/src/secp256k1.c:562:5: note: in expansion of macro ‘ARG_CHECK’
     ARG_CHECK(pubnonces != NULL);
     ^~~~~~~~~
  SOLINK_MODULE(target) Release/obj.target/secp256k1.node
  COPY Release/secp256k1.node
make: ディレクトリ '/tmp/tmp.dZD2bhQsLU/node_modules/tiny-secp256k1/build' から出ます
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN tmp.dZD2bhQsLU@1.0.0 No description
npm WARN tmp.dZD2bhQsLU@1.0.0 No repository field.

+ tiny-secp256k1@1.1.3
added 20 packages from 13 contributors and audited 53 packages in 4.435s
found 0 vulnerabilities

Some strange behaviour. Using Node 14.5.0 I had errors and compilation failure.
Then I downgrade to 13.14.0 and it installs successfully with warnings.
I go back to 14.5.0 just to make sure, and this time it installs successfully with warnings...

A WIP of switching over to use N-API is here: https://github.com/bitcoinjs/tiny-secp256k1/tree/napi

If anyone wants to help, these issues would be gone.

I am hoping to have things moved to N-API before the end-of-year.

Node v10.18.1 also have the same

I have verified that it successfully installs on v10.18.1

Terminal Output

Had similar problem on node 13 and 14. Downgraded to v10.18.1 - build is successful.