<div dir="ltr">Hi all,<div><br></div><div>How can I get a full compiler command line for a given target in CMakeLists project? I want to run Clang-based tool on some targets (using CTest), and it requires same options as used during compilation. </div><div><br></div><div>I know there is CMAKE_EXPORT_COMPILE_COMMANDS but it is not taget-specific.</div><div><br></div><div>There is a similar question on stackoverflow: <a href="https://stackoverflow.com/questions/35808209/get-full-c-compiler-command-line">https://stackoverflow.com/questions/35808209/get-full-c-compiler-command-line</a></div><div>Here author suggets to use get_target_property on a target.  I've tried this, but it does not work when some properties are inherited from libraries (for example include paths).</div><div><br></div><div>Do you have any ideas?</div><div><br></div><div>Thanks,</div><div>Roman</div></div>