Changeset 8622 for code/branches/unity_build/cmake
- Timestamp:
- May 27, 2011, 5:38:43 AM (13 years ago)
- Location:
- code/branches/unity_build/cmake/tools
- Files:
-
- 1 added
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/unity_build/cmake/tools/TargetUtilities.cmake
r8569 r8622 62 62 # 63 63 64 INCLUDE(BuildUnits) 64 65 INCLUDE(CMakeDependentOption) 65 66 INCLUDE(CapitaliseName) … … 120 121 ENDIF() 121 122 LIST(APPEND _${_target_name}_source_files ${_build_unit_file}) 123 LIST(APPEND _${_target_name}_build_units ${_build_unit_file}) 124 # Store the number of files included. May be used for full build units. 125 SET_SOURCE_FILES_PROPERTIES(${_build_unit_file} 126 PROPERTIES BUILD_UNIT_SIZE "${_build_unit_count}") 122 127 ENDIF() 123 128 SET(_add_to_build_unit FALSE) 124 129 ELSEIF(_get_build_unit_file) 130 # Note: ${_file} is relative to the binary directory 125 131 SET(_build_unit_file ${CMAKE_BINARY_DIR}/${_file}) 126 132 SET(_get_build_unit_file FALSE) 127 133 SET(_add_to_build_unit TRUE) 128 134 SET(_build_unit_include_string) 135 SET(_build_unit_count "0") 129 136 ELSE() 130 137 # Default, add source file … … 150 157 IF(_file MATCHES "\\.(c|cc|cpp|cxx)$") 151 158 SET(_build_unit_include_string "${_build_unit_include_string}#include \"${_file}\"\n") 159 MATH(EXPR _build_unit_count "1 + ${_build_unit_count}") 152 160 ENDIF() 153 161 # Don't compile these files, even if they are source files … … 169 177 # Remove potential duplicates 170 178 LIST(REMOVE_DUPLICATES _${_target_name}_files) 179 180 # Full build units 181 IF(NOT _arg_ORXONOX_EXTERNAL AND ENABLE_BUILD_UNITS MATCHES "full") 182 GENERATE_BUILD_UNITS(${_target_name} _${_target_name}_files) 183 ENDIF() 171 184 172 185 # TOLUA_FILES
Note: See TracChangeset
for help on using the changeset viewer.