0

Is it possible to generate a Visual Studio project with node-gyp such that it will include a specified .natvis file? When I manually add a .natvis file to my C++ project, I see that my .vcxproj file is updated with the following block:

  <ItemGroup>
    <Natvis Include="filename.natvis">
      <SubType>Designer</SubType>
    </Natvis>
  </ItemGroup>

Is it possible to configure my binding.gyp file to generate such block?

Thanks

gipouf
  • 1,221
  • 3
  • 15
  • 43

1 Answers1

0

It is possible to specify for the linker which NATVIS file to use. Here is how I specified it in my .gyp file:

"conditions": [
  [
    "OS=='win'",
    {
      "configurations": {
        "Debug": {
          "msvs_settings": {
            "VCLinkerTool": {
              "AdditionalOptions": ['/NATVIS:"$(SolutionDir)..\\natvis\myfile.natvis"']
            }
          }
        }
      }
    }
  ]
]
gipouf
  • 1,221
  • 3
  • 15
  • 43