OLD | NEW |
1 cmake_minimum_required(VERSION 2.8.8) | 1 cmake_minimum_required(VERSION 2.8.8) |
2 | 2 |
3 # FIXME: It may be removed when we use 2.8.12. | 3 # FIXME: It may be removed when we use 2.8.12. |
4 if(CMAKE_VERSION VERSION_LESS 2.8.12) | 4 if(CMAKE_VERSION VERSION_LESS 2.8.12) |
5 # Invalidate a couple of keywords. | 5 # Invalidate a couple of keywords. |
6 set(cmake_2_8_12_INTERFACE) | 6 set(cmake_2_8_12_INTERFACE) |
7 set(cmake_2_8_12_PRIVATE) | 7 set(cmake_2_8_12_PRIVATE) |
8 else() | 8 else() |
9 # Use ${cmake_2_8_12_KEYWORD} intead of KEYWORD in target_link_libraries(). | 9 # Use ${cmake_2_8_12_KEYWORD} intead of KEYWORD in target_link_libraries(). |
10 set(cmake_2_8_12_INTERFACE INTERFACE) | 10 set(cmake_2_8_12_INTERFACE INTERFACE) |
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
160 set(LLVM_INCLUDE_TESTS OFF) | 160 set(LLVM_INCLUDE_TESTS OFF) |
161 endif() | 161 endif() |
162 endif() | 162 endif() |
163 | 163 |
164 set( CLANG_BUILT_STANDALONE 1 ) | 164 set( CLANG_BUILT_STANDALONE 1 ) |
165 set(BACKEND_PACKAGE_STRING "LLVM ${LLVM_PACKAGE_VERSION}") | 165 set(BACKEND_PACKAGE_STRING "LLVM ${LLVM_PACKAGE_VERSION}") |
166 else() | 166 else() |
167 set(BACKEND_PACKAGE_STRING "${PACKAGE_STRING}") | 167 set(BACKEND_PACKAGE_STRING "${PACKAGE_STRING}") |
168 endif() | 168 endif() |
169 | 169 |
170 find_package(LibXml2) | 170 # @LOCALMOD-BEGIN |
171 if (LIBXML2_FOUND) | 171 option(CLANG_ENABLE_LIBXML "Enable libXML" ON) |
172 set(CLANG_HAVE_LIBXML 1) | 172 if (CLANG_ENABLE_LIBXML) |
| 173 find_package(LibXml2) |
| 174 if (LIBXML2_FOUND) |
| 175 set(CLANG_HAVE_LIBXML 1) |
| 176 endif() |
173 endif() | 177 endif() |
| 178 # @LOCALMOD-END |
174 | 179 |
175 set(CLANG_RESOURCE_DIR "" CACHE STRING | 180 set(CLANG_RESOURCE_DIR "" CACHE STRING |
176 "Relative directory from the Clang binary to its resource files.") | 181 "Relative directory from the Clang binary to its resource files.") |
177 | 182 |
178 set(C_INCLUDE_DIRS "" CACHE STRING | 183 set(C_INCLUDE_DIRS "" CACHE STRING |
179 "Colon separated list of directories clang will search for headers.") | 184 "Colon separated list of directories clang will search for headers.") |
180 | 185 |
181 set(GCC_INSTALL_PREFIX "" CACHE PATH "Directory where gcc is installed." ) | 186 set(GCC_INSTALL_PREFIX "" CACHE PATH "Directory where gcc is installed." ) |
182 set(DEFAULT_SYSROOT "" CACHE PATH | 187 set(DEFAULT_SYSROOT "" CACHE PATH |
183 "Default <path> to all compiler invocations for --sysroot=<path>." ) | 188 "Default <path> to all compiler invocations for --sysroot=<path>." ) |
(...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
526 ${CLANG_BINARY_DIR}/share/clang/cmake/ClangTargets.cmake | 531 ${CLANG_BINARY_DIR}/share/clang/cmake/ClangTargets.cmake |
527 DESTINATION share/clang/cmake) | 532 DESTINATION share/clang/cmake) |
528 | 533 |
529 # Also copy ClangConfig.cmake to the build directory so that dependent project
s | 534 # Also copy ClangConfig.cmake to the build directory so that dependent project
s |
530 # can build against a build directory of Clang more easily. | 535 # can build against a build directory of Clang more easily. |
531 configure_file( | 536 configure_file( |
532 ${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules/ClangConfig.cmake | 537 ${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules/ClangConfig.cmake |
533 ${CLANG_BINARY_DIR}/share/clang/cmake/ClangConfig.cmake | 538 ${CLANG_BINARY_DIR}/share/clang/cmake/ClangConfig.cmake |
534 COPYONLY) | 539 COPYONLY) |
535 endif () | 540 endif () |
OLD | NEW |