feat: use pch to speed up builds
This commit is contained in:
parent
850d9fc1c9
commit
f68fb78c80
1 changed files with 16 additions and 1 deletions
|
|
@ -38,9 +38,24 @@ function(qml_module arg_TARGET)
|
||||||
install(FILES "${module_qmldir}" DESTINATION "${module_dir}")
|
install(FILES "${module_qmldir}" DESTINATION "${module_dir}")
|
||||||
install(FILES "${module_typeinfo}" DESTINATION "${module_dir}")
|
install(FILES "${module_typeinfo}" DESTINATION "${module_dir}")
|
||||||
|
|
||||||
target_link_libraries(${arg_TARGET} PRIVATE Qt::Core Qt::Qml ${arg_LIBRARIES})
|
target_link_libraries(${arg_TARGET} PRIVATE caelestia-pch Qt::Core Qt::Qml ${arg_LIBRARIES})
|
||||||
endfunction()
|
endfunction()
|
||||||
|
|
||||||
|
add_library(caelestia-pch INTERFACE)
|
||||||
|
target_precompile_headers(caelestia-pch INTERFACE
|
||||||
|
<qobject.h>
|
||||||
|
<qqmlintegration.h>
|
||||||
|
<qstring.h>
|
||||||
|
<qqmlengine.h>
|
||||||
|
<qloggingcategory.h>
|
||||||
|
<qvariant.h>
|
||||||
|
<qtimer.h>
|
||||||
|
<qdir.h>
|
||||||
|
<qlist.h>
|
||||||
|
<qstringlist.h>
|
||||||
|
<qpointer.h>
|
||||||
|
)
|
||||||
|
|
||||||
qml_module(caelestia
|
qml_module(caelestia
|
||||||
URI Caelestia
|
URI Caelestia
|
||||||
SOURCES
|
SOURCES
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue