diff options
| author | click <none@none> | 2010-05-18 00:17:14 +0200 |
|---|---|---|
| committer | click <none@none> | 2010-05-18 00:17:14 +0200 |
| commit | d607693123ce3f128d36f7bfd0bdc6a858ef9305 (patch) | |
| tree | 8d8068a11fa7383e45517639f2dbc58ec4e7dcf3 /src/scripts | |
| parent | eba819ae7984edeaeab1e3331884a22481dba52f (diff) | |
Add proper use of precompiled headers on linux - this removes an approx 50% reduction of total compiletime
--HG--
branch : trunk
Diffstat (limited to 'src/scripts')
| -rw-r--r-- | src/scripts/CMakeLists.txt | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/src/scripts/CMakeLists.txt b/src/scripts/CMakeLists.txt index 54627091ec2..e51130881f6 100644 --- a/src/scripts/CMakeLists.txt +++ b/src/scripts/CMakeLists.txt @@ -1,11 +1,13 @@ - -########### next target ############### +# Enable precompiled headers when using the GCC compiler. +IF(DO_PCH AND CMAKE_COMPILER_IS_GNUCXX) + INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}) +ENDIF(DO_PCH AND CMAKE_COMPILER_IS_GNUCXX) SET(scripts_STAT_SRCS - ../game/ScriptedEscortAI.cpp - ../game/ScriptedEscortAI.h ../game/ScriptedPch.cpp ../game/ScriptedPch.h + ../game/ScriptedEscortAI.cpp + ../game/ScriptedEscortAI.h ../game/ScriptedCreature.cpp ../game/ScriptedCreature.h ../game/ScriptedFollowerAI.cpp @@ -586,3 +588,7 @@ include_directories( add_library(scripts STATIC ${scripts_STAT_SRCS}) +# Generate precompiled header +IF(DO_PCH AND CMAKE_COMPILER_IS_GNUCXX) + ADD_PRECOMPILED_HEADER(scripts ${CMAKE_SOURCE_DIR}/src/game/ScriptedPch.h) +ENDIF(DO_PCH AND CMAKE_COMPILER_IS_GNUCXX) |
