mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-09-24 02:13:02 -07:00
[Build] Add precompiled headers for Qt-backed executables
Reparsing QtCore/QtGui/QtWidgets/QtNetwork in ~460 client translation units is the dominant compilation cost. Precompile the two common layers: - qtcore_pch.h (Qt Core only; safe even for headless Servatrice) - qtwidgets_pch.h (adds Gui/Widgets/Network; used by Cockatrice and Oracle) target_precompile_headers() requires CMake 3.16, now the project minimum. Estimated 30-50% faster client rebuilds.
This commit is contained in:
parent
61e6a9913e
commit
a03e4350b8
5 changed files with 61 additions and 0 deletions
|
|
@ -112,6 +112,8 @@ qt6_add_executable(
|
|||
MANUAL_FINALIZATION
|
||||
)
|
||||
|
||||
target_precompile_headers(oracle PRIVATE "${CMAKE_SOURCE_DIR}/cmake/pch/qtwidgets_pch.h")
|
||||
|
||||
# ------------------------
|
||||
# Link libraries
|
||||
# ------------------------
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue