[CMake] cmake-qt: controlling includes order

Bill Somerville bill at classdesign.com
Mon Jun 29 07:06:07 EDT 2015


Hi All,

I have an issue with cmake-qt where i need to ensure an include path set 
by the include_directories() command is after include paths that are 
added by the target_link_libraries() command or by the qt5_use_modules() 
command. In both cases the AFTER option on the include_directories() 
command doesn't seem to help me. Most of the Qt include paths get added 
to the end of the list, for some reason QtCore doesn't, and I can't find 
a way to force the ordering I need.

I don't know if this an issue with the Qt CMake files or a generic issue 
with target properties vs. using the include_directories() command.

Any ideas how I can control the ordering or reorder the 
TARGET_INCLUDE_DIRECTORIES property?

TIA
Bill.


More information about the CMake mailing list