cmake: Always build Tint as a static library
The shared library build of Tint is currently broken with CMake, since we set -fvisibility=hidden and do not export any of Tint's publicly used APIs. Change-Id: I63518fbd13e2adbf17aba79114c66d1567b8268b Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/75780 Reviewed-by: Ben Clayton <bclayton@google.com> Commit-Queue: James Price <jrprice@google.com>
This commit is contained in:
parent
9b0008a6d6
commit
38197e7b13
|
@ -56,7 +56,12 @@ if (NOT TARGET libtint)
|
|||
# building the GLSL writer, but currently Dawn does not provide this
|
||||
# third_party dependency. Disable the GLSL writer for now.
|
||||
set(TINT_BUILD_GLSL_WRITER OFF)
|
||||
# TODO(crbug.com/tint/455): Tint does not currently build with CMake when
|
||||
# BUILD_SHARED_LIBS=1, so always build it as static for now.
|
||||
set(BUILD_SHARED_LIBS_SAVED ${BUILD_SHARED_LIBS})
|
||||
set(BUILD_SHARED_LIBS 0)
|
||||
add_subdirectory(${DAWN_TINT_DIR} "${CMAKE_CURRENT_BINARY_DIR}/tint")
|
||||
set(BUILD_SHARED_LIBS ${BUILD_SHARED_LIBS_SAVED})
|
||||
endif()
|
||||
|
||||
if (NOT TARGET libabsl)
|
||||
|
|
Loading…
Reference in New Issue