File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -94,6 +94,17 @@ target_link_libraries(application
9494)
9595
9696
97+ # Precompiled header support
98+ option (LIBRUM_BUILD_USING_PCH "Build using pre-compile header support" ON )
99+ if (LIBRUM_BUILD_USING_PCH)
100+ message ("Compiling using pre-compiled headers" )
101+ target_precompile_headers (application PUBLIC librum_application_pch.hpp ) # PUBLIC - every linking target gets the same PCHs
102+ set (CMAKE_PCH_INSTANTIATE_TEMPLATES ON )
103+ else ()
104+ message (STATUS "Precompiled headers are disabled" )
105+ endif ()
106+
107+
97108# Remove 'address sanitizer' from 'application' target when compiling with anything but GCC.
98109# Okular core has some ODR violations, which lead to 'address sanitizer' failing on startup.
99110# It works well with GCC though, so just remove it when compiling with any other compiler.
Original file line number Diff line number Diff line change 1+ // A file for headers to pre-compile
2+ #pragma once
3+
4+ #include < QObject>
5+ #include < memory>
You can’t perform that action at this time.
0 commit comments