Условия для предкомпиляции заголовков
This commit is contained in:
parent
79c12f1827
commit
0a63e8a6b5
@ -36,7 +36,7 @@ function(myx_target_setup NAME)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(ARG_PCH)
|
if(ARG_PCH)
|
||||||
if(${CMAKE_VERSION} VERSION_GREATER_EQUAL 3.16)
|
if(${CMAKE_VERSION} VERSION_GREATER_EQUAL 3.16 AND PROJECT_IS_TOP_LEVEL OR MYX_USE_LOCAL_DIRECTORIES)
|
||||||
target_precompile_headers(${NAME} PRIVATE ${ARG_PCH})
|
target_precompile_headers(${NAME} PRIVATE ${ARG_PCH})
|
||||||
else()
|
else()
|
||||||
target_compile_options(${NAME} PRIVATE -include ${ARG_PCH})
|
target_compile_options(${NAME} PRIVATE -include ${ARG_PCH})
|
||||||
|
Loading…
Reference in New Issue
Block a user