Changeset View
Changeset View
Standalone View
Standalone View
source/creator/CMakeLists.txt
| # SPDX-License-Identifier: GPL-2.0-or-later | # SPDX-License-Identifier: GPL-2.0-or-later | ||||
| # Copyright 2006 Blender Foundation. All rights reserved. | # Copyright 2006 Blender Foundation. All rights reserved. | ||||
| blender_include_dirs( | set(INC | ||||
| ../../intern/clog | ../../intern/clog | ||||
| ../../intern/guardedalloc | ../../intern/guardedalloc | ||||
| ../blender/blenkernel | ../blender/blenkernel | ||||
| ../blender/blenlib | ../blender/blenlib | ||||
| ../blender/blenloader | ../blender/blenloader | ||||
| ../blender/depsgraph | ../blender/depsgraph | ||||
| ../blender/editors/include | ../blender/editors/include | ||||
| ../blender/gpu | ../blender/gpu | ||||
| Show All 17 Lines | if(WITH_TBB) | ||||
| # that it is initialized before MKL and static library initialization order issues are avoided. | # that it is initialized before MKL and static library initialization order issues are avoided. | ||||
| # | # | ||||
| # This isn't fully robust but seems to work. | # This isn't fully robust but seems to work. | ||||
| list(INSERT LIB 0 ${TBB_LIBRARIES}) | list(INSERT LIB 0 ${TBB_LIBRARIES}) | ||||
| list(INSERT LIB 0 bf_blenkernel) | list(INSERT LIB 0 bf_blenkernel) | ||||
| endif() | endif() | ||||
| if(WIN32) | if(WIN32) | ||||
| blender_include_dirs(../../intern/utfconv) | list(APPEND INC ../../intern/utfconv) | ||||
| endif() | endif() | ||||
| if(WITH_LIBMV) | if(WITH_LIBMV) | ||||
| blender_include_dirs(../../intern/libmv) | list(APPEND INC ../../intern/libmv) | ||||
| add_definitions(-DWITH_LIBMV) | add_definitions(-DWITH_LIBMV) | ||||
| endif() | endif() | ||||
| if(WITH_CYCLES) | if(WITH_CYCLES) | ||||
| if(WITH_CYCLES_LOGGING) | if(WITH_CYCLES_LOGGING) | ||||
| blender_include_dirs(../../intern/cycles/blender) | list(APPEND INC ../../intern/cycles/blender) | ||||
| add_definitions(-DWITH_CYCLES_LOGGING) | add_definitions(-DWITH_CYCLES_LOGGING) | ||||
| endif() | endif() | ||||
| endif() | endif() | ||||
| if(WITH_CODEC_FFMPEG) | if(WITH_CODEC_FFMPEG) | ||||
| add_definitions(-DWITH_FFMPEG) | add_definitions(-DWITH_FFMPEG) | ||||
| endif() | endif() | ||||
| if(WITH_TBB) | if(WITH_TBB) | ||||
| blender_include_dirs(${TBB_INCLUDE_DIRS}) | list(APPEND INC ${TBB_INCLUDE_DIRS}) | ||||
| if(WIN32) | if(WIN32) | ||||
| # For `pragma` that links `tbbmalloc_proxy.lib`. | # For `pragma` that links `tbbmalloc_proxy.lib`. | ||||
| link_directories(${LIBDIR}/tbb/lib) | link_directories(${LIBDIR}/tbb/lib) | ||||
| endif() | endif() | ||||
| endif() | endif() | ||||
| if(WITH_PYTHON) | if(WITH_PYTHON) | ||||
| blender_include_dirs(../blender/python) | list(APPEND INC ../blender/python) | ||||
| add_definitions(-DWITH_PYTHON) | add_definitions(-DWITH_PYTHON) | ||||
| if(WITH_PYTHON_SECURITY) | if(WITH_PYTHON_SECURITY) | ||||
| add_definitions(-DWITH_PYTHON_SECURITY) | add_definitions(-DWITH_PYTHON_SECURITY) | ||||
| endif() | endif() | ||||
| endif() | endif() | ||||
| if(WITH_HEADLESS) | if(WITH_HEADLESS) | ||||
| add_definitions(-DWITH_HEADLESS) | add_definitions(-DWITH_HEADLESS) | ||||
| endif() | endif() | ||||
| if(WITH_SDL) | if(WITH_SDL) | ||||
| if(WITH_SDL_DYNLOAD) | if(WITH_SDL_DYNLOAD) | ||||
| blender_include_dirs(../../extern/sdlew/include) | list(APPEND INC ../../extern/sdlew/include) | ||||
| add_definitions(-DWITH_SDL_DYNLOAD) | add_definitions(-DWITH_SDL_DYNLOAD) | ||||
| endif() | endif() | ||||
| add_definitions(-DWITH_SDL) | add_definitions(-DWITH_SDL) | ||||
| endif() | endif() | ||||
| if(WITH_BINRELOC) | if(WITH_BINRELOC) | ||||
| blender_include_dirs(${BINRELOC_INCLUDE_DIRS}) | list(APPEND INC ${BINRELOC_INCLUDE_DIRS}) | ||||
| add_definitions(-DWITH_BINRELOC) | add_definitions(-DWITH_BINRELOC) | ||||
| endif() | endif() | ||||
| if(WITH_FREESTYLE) | if(WITH_FREESTYLE) | ||||
| blender_include_dirs(../blender/freestyle) | list(APPEND INC ../blender/freestyle) | ||||
| add_definitions(-DWITH_FREESTYLE) | add_definitions(-DWITH_FREESTYLE) | ||||
| endif() | endif() | ||||
| if(WITH_XR_OPENXR) | if(WITH_XR_OPENXR) | ||||
| add_definitions(-DWITH_XR_OPENXR) | add_definitions(-DWITH_XR_OPENXR) | ||||
| endif() | endif() | ||||
| if(WITH_GMP) | if(WITH_GMP) | ||||
| blender_include_dirs(${GMP_INCLUDE_DIRS}) | list(APPEND INC ${GMP_INCLUDE_DIRS}) | ||||
| add_definitions(-DWITH_GMP) | add_definitions(-DWITH_GMP) | ||||
| endif() | endif() | ||||
| if(WITH_OPENCOLORIO) | if(WITH_OPENCOLORIO) | ||||
| add_definitions(-DWITH_OCIO) | add_definitions(-DWITH_OCIO) | ||||
| endif() | endif() | ||||
| # Setup the EXE sources and `buildinfo`. | # Setup the EXE sources and `buildinfo`. | ||||
| ▲ Show 20 Lines • Show All 1,169 Lines • ▼ Show 20 Lines | |||||
| setup_platform_linker_flags(blender) | setup_platform_linker_flags(blender) | ||||
| setup_platform_linker_libs(blender) | setup_platform_linker_libs(blender) | ||||
| if(DEFINED PLATFORM_SYMBOLS_MAP) | if(DEFINED PLATFORM_SYMBOLS_MAP) | ||||
| set_target_properties(blender PROPERTIES LINK_DEPENDS ${PLATFORM_SYMBOLS_MAP}) | set_target_properties(blender PROPERTIES LINK_DEPENDS ${PLATFORM_SYMBOLS_MAP}) | ||||
| endif() | endif() | ||||
| blender_target_include_dirs(blender ${INC}) | |||||
| # ----------------------------------------------------------------------------- | # ----------------------------------------------------------------------------- | ||||
| # USD registry. | # USD registry. | ||||
| # USD requires a set of JSON files that define the standard schemas. | # USD requires a set of JSON files that define the standard schemas. | ||||
| # These files are required at runtime. | # These files are required at runtime. | ||||
| if(WITH_USD) | if(WITH_USD) | ||||
| add_definitions(-DWITH_USD) | add_definitions(-DWITH_USD) | ||||
| ▲ Show 20 Lines • Show All 56 Lines • Show Last 20 Lines | |||||