node-gphoto2 icon indicating copy to clipboard operation
node-gphoto2 copied to clipboard

change binding.gyp for mac for build the package

Open gentilmente opened this issue 3 years ago • 1 comments

I`m not an expert, sorry if this is not the correct way of ask for this change. It solved me a building problem.

'cflags': [ '--std=c++11' ],

'OTHER_CPLUSPLUSFLAGS' : [ '-std=c++11',

In both cases change it to 14

My system: mac osx 12.0.1 updated xcode cli tools node 14.16.0

gentilmente avatar Nov 13 '21 11:11 gentilmente

In the same direction, in order to be able to upgrade node to v16 you need to folow these instructions https://github.com/electron/electron/issues/18397 in bining.cc:

extern "C" {
  NAN_MODULE_INIT(init) {
    Nan::HandleScope scope;
    GPhoto2::Initialize(target);
    GPCamera::Initialize(target);
  }

  #if NODE_MAJOR_VERSION >= 10
  NAN_MODULE_WORKER_ENABLED(gphoto2, init)
  #else
  NODE_MODULE(gphoto2, init)
  #endif
}

gentilmente avatar Nov 29 '21 22:11 gentilmente