<div dir="ltr"><div>I have a project that I'm updating from Cmake 3.5 to 3.12.</div><div><br></div><div>In the project, I have UI libraries that use other libraries, both of which use Qt 5.6. </div><div>The lowest-level library uses AUTOUIC and I see the headers are generated in the new lib_autogen/include_BUILD_CONFIG directory.</div><div><br></div><div>When my higher level library tries to use the lower level library, I get the error that it can't find the auto-generated headers. It only seems to have trouble finding about six of two dozen ui_***.h files. </div><div><br></div><div>How can I get my lower level libraries to include the generated header files so they're available to the higher level library that's using it?</div><div><br></div><div>I'm using </div><div>cmake 3.12<br></div><div>Qt 5.6 </div><div>Visual Studio 2015</div><div><br></div><div>I tried creating a work-around where in the CMakeLists.txt of my lowest level directory I add </div><div><br></div><div><div># CMake 10+ has a bug where automoc header files aren't found</div><div>SET(COMPONENTS_UIC_HDRS_DIR "${CMAKE_CURRENT_BINARY_DIR}/ComponentsLib_autogen/include_${<b>CMAKE_BUILD_TYPE</b>}")</div><div>message("** COMPONENTS AUTOUIC autogen dir: ${COMPONENTS_UIC_HDRS_DIR}")</div><div><b>target_include_directories</b>(ComponentsLib INTERFACE ${COMPONENTS_UIC_HDRS_DIR})</div><div> </div></div><div>but of course the CMAKE_BUILD_TYPE isn't available to CMake at this time. I'd have to move the headers into a place common to the various (Debug/Release) configurations or something.</div><div><br></div><div>Thanks!</div><div>-Jim</div><div><br></div><div><br></div></div>