# List of source created by Unity

**URL:** https://discourse.cmake.org/t/list-of-source-created-by-unity/3407
**Category:** Usage
**Created:** [May 25, 2021, 6:50pm UTC](https://discourse.cmake.org/t/list-of-source-created-by-unity/3407 "2021-05-25T18:50:48Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Mario\_Not64](https://discourse.cmake.org/user_avatar/discourse.cmake.org/mario_not64/32/1478_2.png) [@Mario\_Not64](https://discourse.cmake.org/u/Mario_Not64)
#### Post date: [May 25, 2021, 6:50pm UTC](https://discourse.cmake.org/t/list-of-source-created-by-unity/3407/1 "2021-05-25T18:50:48Z")

</div>

Is it possible to get the list of source files created by a Unity build for a perticular executable ?

I am using cppcheck and would like it to run on the unity cxx autogenerated files. I’m getting the sources files from the SOURCES property of the executable.It returns the list of “real” source code intead of the unity build files.

Regards,

Mario.

---

<div class="post-metadata">

### Author: ![ben.boeckel](https://discourse.cmake.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.cmake.org/u/ben.boeckel)
#### Post date: [May 25, 2021, 8:28pm UTC](https://discourse.cmake.org/t/list-of-source-created-by-unity/3407/2 "2021-05-25T20:28:01Z")

</div>

Hmm. I suspect this information actually lives in `compile_commands.json`. Other than that, the `cmake-file-api` is probably the best way right now if the information is available there.
