Skip to content

Commit

Permalink
feat: support node 16 (#71)
Browse files Browse the repository at this point in the history
  • Loading branch information
ewanharris committed Apr 26, 2021
1 parent d1322f6 commit 1bc0ea2
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 4 deletions.
2 changes: 0 additions & 2 deletions binding.gyp
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,6 @@
'-fno-exceptions'
],
'xcode_settings': {
'OTHER_CPLUSPLUSFLAGS' : [ '-std=c++11', '-stdlib=libc++' ],
'OTHER_LDFLAGS': [ '-stdlib=libc++' ],
'MACOSX_DEPLOYMENT_TARGET': '10.11',
'GCC_ENABLE_CPP_EXCEPTIONS': 'YES'
},
Expand Down
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"devices"
],
"dependencies": {
"@mapbox/node-pre-gyp": "^1.0.1",
"@mapbox/node-pre-gyp": "^1.0.4",
"debug": "^4.2.0",
"nan": "^2.14.2",
"node-pre-gyp-init": "^1.2.0"
Expand Down Expand Up @@ -58,7 +58,8 @@
"12.11.0": 72,
"13.5.0": 79,
"14.13.1": 83,
"15.0.1": 88
"15.0.1": 88,
"16.0.0": 93
}
},
"license": "Apache-2.0",
Expand Down
5 changes: 5 additions & 0 deletions src/node-ios-device.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,12 @@ NAN_MODULE_INIT(init) {
Nan::Set(target, Nan::New("startLogRelay").ToLocalChecked(), Nan::GetFunction(Nan::New<FunctionTemplate>(startLogRelay)).ToLocalChecked());
Nan::Set(target, Nan::New("stopLogRelay").ToLocalChecked(), Nan::GetFunction(Nan::New<FunctionTemplate>(stopLogRelay)).ToLocalChecked());

#if NODE_MAJOR_VERSION >= 12
node::Environment* env = node::GetCurrentEnvironment(Nan::GetCurrentContext());
node::AtExit(env, cleanup, NULL);
#else
node::AtExit(cleanup);
#endif
}

NODE_MODULE(node_ios_device, init)
23 changes: 23 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,21 @@
semver "^7.3.4"
tar "^6.1.0"

"@mapbox/node-pre-gyp@^1.0.4":
version "1.0.4"
resolved "https://registry.yarnpkg.com/@mapbox/node-pre-gyp/-/node-pre-gyp-1.0.4.tgz#6c76e7a40138eac39e1a4dc869a083e43e236c00"
integrity sha512-M669Qo4nRT7iDmQEjQYC7RU8Z6dpz9UmSbkJ1OFEja3uevCdLKh7IZZki7L1TZj02kRyl82snXFY8QqkyfowrQ==
dependencies:
detect-libc "^1.0.3"
https-proxy-agent "^5.0.0"
make-dir "^3.1.0"
node-fetch "^2.6.1"
nopt "^5.0.0"
npmlog "^4.1.2"
rimraf "^3.0.2"
semver "^7.3.4"
tar "^6.1.0"

"@octokit/auth-token@^2.4.4":
version "2.4.5"
resolved "https://registry.yarnpkg.com/@octokit/auth-token/-/auth-token-2.4.5.tgz#568ccfb8cb46f36441fac094ce34f7a875b197f3"
Expand Down Expand Up @@ -284,6 +299,14 @@ http-proxy-agent@^4.0.1:
agent-base "6"
debug "4"

https-proxy-agent@^5.0.0:
version "5.0.0"
resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-5.0.0.tgz#e2a90542abb68a762e0a0850f6c9edadfd8506b2"
integrity sha512-EkYm5BcKUGiduxzSt3Eppko+PiNWNEpa4ySk9vTC6wDsQJW9rHSa+UhGNJoRYp7bz6Ht1eaRIa6QaJqO5rCFbA==
dependencies:
agent-base "6"
debug "4"

inflight@^1.0.4:
version "1.0.6"
resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9"
Expand Down

0 comments on commit 1bc0ea2

Please sign in to comment.