Hi I'm using this gyp file below to try and get my build going with visual studio 2022. The build fails with error "error C2118: negative subscript", but I believe the issue is due to the build being done with x86/cl.exe, as per the logs. How can I set gyp to force it to use x64/cl.exe? Here is my gyp file.
{
'targets': [
{
'target_name': 'keyring-go',
'sources': [ 'src/keyring.cc' ],
'include_dirs': ["<!@(node -p \"require('node-addon-api').include\")"],
'dependencies': ["<!(node -p \"require('node-addon-api').gyp\")"],
'cflags!': [ '-fno-exceptions' ],
'cflags_cc!': [ '-fno-exceptions' ],
'xcode_settings': {
'GCC_ENABLE_CPP_EXCEPTIONS': 'YES',
'CLANG_CXX_LIBRARY': 'libc++',
'MACOSX_DEPLOYMENT_TARGET': '12'
},
'msvs_settings': {
'VCCLCompilerTool': {
'ExceptionHandling': 1,
'RuntimeLibrary': 2
},
},
'conditions': [
['OS=="win"', {
'default_configuration': 'Release_x64',
'configurations':
{
'Debug_x64': {
'inherit_from': ['Debug'],
'msvs_configuration_platform': 'x64',
},
'Release_x64': {
'inherit_from': ['Release'],
'msvs_configuration_platform': 'x64',
},
},
'defines': [
'_MSC_VER=1935',
],
'sources': [ 'src/c_build/win/keyring.cc' ],
"libraries": [
"<!(cd)/keyring.dll"
],
}]
]
}
]
}