# Add /NATVIS abstraction for linker property

**URL:** https://discourse.cmake.org/t/add-natvis-abstraction-for-linker-property/14043
**Category:** Development
**Created:** [May 4, 2025, 6:36pm UTC](https://discourse.cmake.org/t/add-natvis-abstraction-for-linker-property/14043 "2025-05-04T18:36:39Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![leha-bot](https://discourse.cmake.org/user_avatar/discourse.cmake.org/leha-bot/32/921_2.png) [@leha-bot](https://discourse.cmake.org/u/leha-bot)
#### Post date: [May 4, 2025, 6:36pm UTC](https://discourse.cmake.org/t/add-natvis-abstraction-for-linker-property/14043/1 "2025-05-04T18:36:39Z")

</div>

It could be like MSVC\_LINKER\_NATVIS\_FILE and accept an list of files (also from generator expressions as some library authors could add .natvis files into target\_sources() usage requirement (e.g. nlohmann json: [json/CMakeLists.txt at 697c7e557c84c37e88beca4eb591e4ac7b0598b8 · nlohmann/json · GitHub](https://github.com/nlohmann/json/blob/697c7e557c84c37e88beca4eb591e4ac7b0598b8/CMakeLists.txt#L143) )  
More info about linker flag:  
[/NATVIS (Add Natvis to PDB) | Microsoft Learn](https://learn.microsoft.com/en-us/cpp/build/reference/natvis-add-natvis-to-pdb?view=msvc-170)

---

<div class="post-metadata">

### Author: ![brad.king](https://discourse.cmake.org/user_avatar/discourse.cmake.org/brad.king/32/11_2.png) [@brad.king](https://discourse.cmake.org/u/brad.king)
#### Post date: [May 5, 2025, 1:14pm UTC](https://discourse.cmake.org/t/add-natvis-abstraction-for-linker-property/14043/2 "2025-05-05T13:14:31Z")

</div>

There is related discussion in [CMake Issue 26278](https://gitlab.kitware.com/cmake/cmake/-/issues/26278).
