diff options
author | Ray Molenkamp <github@lazydodo.com> | 2021-02-24 17:13:37 +0300 |
---|---|---|
committer | Ray Molenkamp <github@lazydodo.com> | 2021-02-24 17:13:37 +0300 |
commit | 4fb0c83c1c8529b61d38d8a409caf58d05a53bd9 (patch) | |
tree | 18ce99c74a8305a63f93b4ef57a5648818d3352c /build_files/build_environment/cmake/llvm.cmake | |
parent | 5be72125bf4dfddf5dfe720caa12b3163f540faf (diff) |
Cmake/deps: Update OSL to 1.11.10.0
This bumps OSL to 1.11.10.0. OSL Has a new build time
dependency: Clang, and more importantly it expects
clang and llvm to share a library folder, which it
previously for us did not.
This patch changes:
-OSL Update to 1.11.10.0
-refactor the llvm/clang/clang-tools-extra builds into the llvm
build using the llvm-project tarball for building that has all
of the subprojects in it.
-update ispc/openmp builds since clang no longer its own dependency
and they have to depend on the llvm build now.
-Update the windows builder to use the 64 bit host tools since it
ran out of ram linking clang
-Since OSL now needs clang to link successfully a findclang.cmake
has been provided for linux/OSX
Differential Revision: https://developer.blender.org/D10212
Reviewed By: brecht, sebbas, sybren
Diffstat (limited to 'build_files/build_environment/cmake/llvm.cmake')
-rw-r--r-- | build_files/build_environment/cmake/llvm.cmake | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/build_files/build_environment/cmake/llvm.cmake b/build_files/build_environment/cmake/llvm.cmake index a4c7ccd9e27..da2f7364e4a 100644 --- a/build_files/build_environment/cmake/llvm.cmake +++ b/build_files/build_environment/cmake/llvm.cmake @@ -22,6 +22,15 @@ else() set(LLVM_TARGETS X86) endif() +if(APPLE) + set(LLVM_XML2_ARGS + -DLIBXML2_LIBRARY=${LIBDIR}/xml2/lib/libxml2.a + ) + set(LLVM_BUILD_CLANG_TOOLS_EXTRA ^^clang-tools-extra) + set(BUILD_CLANG_TOOLS ON) +endif() + + set(LLVM_EXTRA_ARGS -DLLVM_USE_CRT_RELEASE=MD -DLLVM_USE_CRT_DEBUG=MDd @@ -31,6 +40,8 @@ set(LLVM_EXTRA_ARGS -DLLVM_ENABLE_TERMINFO=OFF -DLLVM_BUILD_LLVM_C_DYLIB=OFF -DLLVM_ENABLE_UNWIND_TABLES=OFF + -DLLVM_ENABLE_PROJECTS=clang${LLVM_BUILD_CLANG_TOOLS_EXTRA} + ${LLVM_XML2_ARGS} ) if(WIN32) @@ -45,7 +56,9 @@ ExternalProject_Add(ll DOWNLOAD_DIR ${DOWNLOAD_DIR} URL_HASH MD5=${LLVM_HASH} CMAKE_GENERATOR ${LLVM_GENERATOR} + LIST_SEPARATOR ^^ PREFIX ${BUILD_DIR}/ll + SOURCE_SUBDIR llvm PATCH_COMMAND ${PATCH_CMD} -p 1 -d ${BUILD_DIR}/ll/src/ll < ${PATCH_DIR}/llvm.diff CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${LIBDIR}/llvm ${DEFAULT_CMAKE_FLAGS} ${LLVM_EXTRA_ARGS} INSTALL_DIR ${LIBDIR}/llvm @@ -65,3 +78,11 @@ if(MSVC) DEPENDEES mkdir update patch download configure build install ) endif() + +# We currently do not build libxml2 on Windows. +if(APPLE) + add_dependencies( + ll + external_xml2 + ) +endif() |