Changeset 5963 for code/trunk
- Timestamp:
- Oct 18, 2009, 11:39:32 PM (15 years ago)
- Location:
- code/trunk/cmake
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/cmake/CompilerConfigMSVC.cmake
r5929 r5963 68 68 ADD_COMPILER_FLAGS("-D__WIN32__ -D_WIN32" CACHE) 69 69 ADD_COMPILER_FLAGS("-D_CRT_SECURE_NO_WARNINGS" CACHE) 70 71 # We need this flag to hack-disable IntelliSense for certain files/projects 72 # Our precompiled headers should not be larger than 50MB anyway 73 # because otherwise they get rendered useless due to too many file fragments 74 REMOVE_COMPILER_FLAGS("-Zm1000" CACHE) 70 75 71 76 # Overwrite CMake default flags here. -
code/trunk/cmake/SourceFileUtilities.cmake
r5929 r5963 48 48 ENDIF() 49 49 IF(NOT DISABLE_COMPILATIONS) 50 SET(_compilation_file ${CMAKE_CURRENT_BINARY_DIR}/${_compilation_name}) 50 51 SET(_include_string) 51 52 FOREACH(_file2 ${_compilation}) 52 53 SET(_include_string "${_include_string}#include \"${_file2}\"\n") 53 54 ENDFOREACH(_file2) 54 IF(EXISTS ${CMAKE_CURRENT_BINARY_DIR}/${_compilation_name})55 FILE(READ ${ CMAKE_CURRENT_BINARY_DIR}/${_compilation_name} _include_string_file)55 IF(EXISTS ) 56 FILE(READ ${_compilation_file} _include_string_file) 56 57 ENDIF() 57 58 IF(NOT _include_string STREQUAL "${_include_string_file}") 58 FILE(WRITE ${ CMAKE_CURRENT_BINARY_DIR}/${_compilation_name} "${_include_string}")59 FILE(WRITE ${_compilation_file} "${_include_string}") 59 60 ENDIF() 60 LIST(APPEND _fullpath_sources ${CMAKE_CURRENT_BINARY_DIR}/${_compilation_name}) 61 LIST(APPEND _fullpath_sources ${_compilation_file}) 62 # MSVC hack that excludes the compilations from the intellisense database 63 # (There is a bug with the "-" instead of "/". Only works for "Zm#" argument) 64 IF(MSVC) 65 SET_SOURCE_FILES_PROPERTIES(${_compilation_file} PROPERTIES COMPILE_FLAGS "-Zm1000") 66 ENDIF() 61 67 ENDIF() 62 68 SET(_compilation_name) -
code/trunk/cmake/TargetUtilities.cmake
r5929 r5963 181 181 ENDFOREACH(_file) 182 182 183 184 183 185 # Add the library/executable 184 186 IF("${_target_type}" STREQUAL "LIBRARY") … … 190 192 ENDIF() 191 193 194 195 192 196 # Change library prefix to "lib" 193 197 IF(MSVC AND ${_target_type} STREQUAL "LIBRARY") … … 195 199 PREFIX "lib" 196 200 ) 201 ENDIF() 202 203 # MSVC hack to exclude external library sources from the intellisense database 204 # (IntelliSense stops working when adding "-Zm1000" as compile flag. "/Zm1000" 205 # would not work because of the slash) 206 IF(_arg_ORXONOX_EXTERNAL AND MSVC) 207 SET_TARGET_PROPERTIES(${_target_name} PROPERTIES COMPILE_FLAGS "-Zm1000") 197 208 ENDIF() 198 209
Note: See TracChangeset
for help on using the changeset viewer.