mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 13:18:28 +00:00
enable precompile headers only for the Debug and Release build
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15663 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
c1106b1d06
commit
734ea8819e
@ -97,9 +97,11 @@ if(MSVC AND NOT disable-pch)
|
|||||||
macro(lyx_add_msvc_pch name_)
|
macro(lyx_add_msvc_pch name_)
|
||||||
SET_SOURCE_FILES_PROPERTIES(${${name_}_sources} PROPERTIES COMPILE_FLAGS "/Yuconfig.h /Fp\$(IntDir)/config.pch")
|
SET_SOURCE_FILES_PROPERTIES(${${name_}_sources} PROPERTIES COMPILE_FLAGS "/Yuconfig.h /Fp\$(IntDir)/config.pch")
|
||||||
SET_SOURCE_FILES_PROPERTIES(${CMAKE_BINARY_DIR}/config_pch.C PROPERTIES COMPILE_FLAGS "/Ycconfig.h /Fp\$(IntDir)/config.pch")
|
SET_SOURCE_FILES_PROPERTIES(${CMAKE_BINARY_DIR}/config_pch.C PROPERTIES COMPILE_FLAGS "/Ycconfig.h /Fp\$(IntDir)/config.pch")
|
||||||
add_definitions(/DLYX_PRECOMPILED_HEADERS)
|
|
||||||
set(${name_}_sources ${${name_}_sources} ${CMAKE_BINARY_DIR}/config_pch.C ${CMAKE_BINARY_DIR}/pcheaders.h)
|
set(${name_}_sources ${${name_}_sources} ${CMAKE_BINARY_DIR}/config_pch.C ${CMAKE_BINARY_DIR}/pcheaders.h)
|
||||||
endmacro(lyx_add_msvc_pch)
|
endmacro(lyx_add_msvc_pch)
|
||||||
|
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /DLYX_PCH_STL /DLYX_PCH_BOOST /DLYX_PCH_QT4")
|
||||||
|
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /DLYX_PCH_STL /DLYX_PCH_BOOST /DLYX_PCH_QT4")
|
||||||
|
|
||||||
else(MSVC AND NOT disable-pch)
|
else(MSVC AND NOT disable-pch)
|
||||||
set(disable-pch TRUE CACHE TYPE STRING)
|
set(disable-pch TRUE CACHE TYPE STRING)
|
||||||
macro(lyx_add_msvc_pch)
|
macro(lyx_add_msvc_pch)
|
||||||
|
@ -168,12 +168,6 @@
|
|||||||
#pragma warning( disable : 4800 ) //: forcing value to bool 'true' or 'false' (performance warning)
|
#pragma warning( disable : 4800 ) //: forcing value to bool 'true' or 'false' (performance warning)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef LYX_PRECOMPILED_HEADERS
|
#include "pcheaders.h"
|
||||||
# include "pcheaders.h"
|
|
||||||
# ifdef LYX_BUILD_QT4_FRONTEND
|
|
||||||
# include <QtCore>
|
|
||||||
# include <QtGUI>
|
|
||||||
# endif
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -10,6 +10,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef LYX_PCH_BOOST
|
||||||
#include <boost/any.hpp>
|
#include <boost/any.hpp>
|
||||||
#include <boost/array.hpp>
|
#include <boost/array.hpp>
|
||||||
#include <boost/assert.hpp>
|
#include <boost/assert.hpp>
|
||||||
@ -34,14 +35,15 @@
|
|||||||
#include <boost/tuple/tuple.hpp>
|
#include <boost/tuple/tuple.hpp>
|
||||||
#include <boost/utility.hpp>
|
#include <boost/utility.hpp>
|
||||||
#include <boost/version.hpp>
|
#include <boost/version.hpp>
|
||||||
|
|
||||||
#if BOOST_VERSION < 103300
|
#if BOOST_VERSION < 103300
|
||||||
# include <boost/test/detail/nullstream.hpp>
|
# include <boost/test/detail/nullstream.hpp>
|
||||||
#else
|
#else
|
||||||
# include <boost/test/utils/nullstream.hpp>
|
# include <boost/test/utils/nullstream.hpp>
|
||||||
#endif
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef LYX_PCH_STL
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <cerrno>
|
#include <cerrno>
|
||||||
#include <cassert>
|
#include <cassert>
|
||||||
@ -69,3 +71,10 @@
|
|||||||
#include <string>
|
#include <string>
|
||||||
#include <utility>
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#if defined(LYX_PCH_QT4) && defined(LYX_BUILD_QT4_FRONTEND)
|
||||||
|
#include <QtCore>
|
||||||
|
#include <QtGUI>
|
||||||
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user