mirror of
https://github.com/blender/blender
synced 2026-10-25 03:07:01 +03:00
Seems like we forgot to remove the Tiff library linking when we moved to using openimageio for loading tiff files. Pull Request: https://projects.blender.org/blender/blender/pulls/158551
47 lines
1.1 KiB
CMake
47 lines
1.1 KiB
CMake
# SPDX-FileCopyrightText: 2002-2022 Blender Authors
|
|
#
|
|
# SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
set(TIFF_EXTRA_ARGS
|
|
-DZLIB_LIBRARY=${LIBDIR}/zlib/lib/${ZLIB_LIBRARY}
|
|
-DZLIB_INCLUDE_DIR=${LIBDIR}/zlib/include
|
|
-DJPEG_LIBRARY=${LIBDIR}/jpeg/lib/${JPEG_LIBRARY}
|
|
-DJPEG_INCLUDE_DIR=${LIBDIR}/jpeg/include
|
|
-DPNG_STATIC=ON
|
|
-DBUILD_SHARED_LIBS=OFF
|
|
-Dlzma=OFF
|
|
-Djbig=OFF
|
|
-Dzstd=OFF
|
|
-Dwebp=OFF
|
|
-Dlerc=OFF
|
|
-Dtiff-tests=OFF
|
|
-Dsphinx=OFF
|
|
)
|
|
|
|
if(APPLE)
|
|
set(TIFF_EXTRA_ARGS
|
|
${TIFF_EXTRA_ARGS}
|
|
# Work around issue where homebrew's libdeflate can be prioritized over our own dependency during linking if installed.
|
|
-DDeflate_LIBRARY=${LIBDIR}/deflate/lib/libdeflate${LIBEXT}
|
|
)
|
|
endif()
|
|
|
|
ExternalProject_Add(external_tiff
|
|
URL file://${PACKAGE_DIR}/${TIFF_FILE}
|
|
DOWNLOAD_DIR ${DOWNLOAD_DIR}
|
|
URL_HASH ${TIFF_HASH_TYPE}=${TIFF_HASH}
|
|
PREFIX ${BUILD_DIR}/tiff
|
|
CMAKE_GENERATOR ${PLATFORM_ALT_GENERATOR}
|
|
CMAKE_ARGS
|
|
-DCMAKE_INSTALL_PREFIX=${LIBDIR}/tiff
|
|
${DEFAULT_CMAKE_FLAGS}
|
|
${TIFF_EXTRA_ARGS}
|
|
|
|
INSTALL_DIR ${LIBDIR}/tiff
|
|
)
|
|
|
|
add_dependencies(
|
|
external_tiff
|
|
external_zlib
|
|
external_jpeg
|
|
)
|