Skip to content

Instantly share code, notes, and snippets.

@a7ul
Last active June 13, 2018 07:09
Show Gist options
  • Save a7ul/8fbd016dc1386aea5b5ff395590d4843 to your computer and use it in GitHub Desktop.
Save a7ul/8fbd016dc1386aea5b5ff395590d4843 to your computer and use it in GitHub Desktop.
blog-addons-first
node_modules
*.log
build
{
"targets": [{
"target_name": "testaddon",
"cflags!": [ "-fno-exceptions" ],
"cflags_cc!": [ "-fno-exceptions" ],
"sources": [
"cppsrc/main.cpp"
],
'include_dirs': [
"<!@(node -p \"require('node-addon-api').include\")"
],
'libraries': [],
'dependencies': [
"<!(node -p \"require('node-addon-api').gyp\")"
],
'defines': [ 'NAPI_DISABLE_CPP_EXCEPTIONS' ]
}]
}
{
"name": "test-addon",
"version": "1.0.0",
"description": "",
"main": "index.js",
"gypfile": true,
"scripts": {
"build": "node-gyp rebuild",
"clean": "node-gyp clean"
},
"author": "",
"license": "ISC",
"devDependencies": {
"node-gyp": "^3.7.0"
},
"dependencies": {
"node-addon-api": "^1.3.0"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment