diff options
author | Martin Felke <martin.felke@googlemail.com> | 2018-11-13 17:08:38 +0300 |
---|---|---|
committer | Martin Felke <martin.felke@googlemail.com> | 2018-11-13 17:08:38 +0300 |
commit | ed348890c1d4b27fa36820e721d9aac9640d9089 (patch) | |
tree | b401764adbeb706c87ad03b2bf735bc22627bcea /CMakeLists.txt | |
parent | 3618df78a8b17d9b941da4d76d94a3ec2f64b4c2 (diff) | |
parent | 9879ea8a53adc6e02cbf6e42822539deae3dace4 (diff) |
Merge remote-tracking branch 'origin/blender2.8' into fracture_modifier-2.8
# Conflicts:
# release/scripts/addons
# release/scripts/addons_contrib
# source/blender/blenkernel/BKE_customdata.h
# source/blender/blenkernel/intern/bvhutils.c
# source/blender/depsgraph/intern/depsgraph_query_filter.cc
# source/blender/editors/interface/interface.c
# source/blender/editors/object/object_modifier.c
# source/blender/editors/object/object_relations.c
# source/blender/makesrna/RNA_access.h
# source/blender/modifiers/intern/MOD_boolean.c
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 53 |
1 files changed, 22 insertions, 31 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 0379dff2db8..399181838c8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -166,7 +166,6 @@ option_defaults_init( _init_SDL _init_FFTW3 _init_OPENSUBDIV - _init_SYSTEM_OPENJPG ) # customize... @@ -183,13 +182,11 @@ if(UNIX AND NOT APPLE) set(_init_SDL OFF) set(_init_FFTW3 OFF) set(_init_OPENSUBDIV OFF) - set(_init_SYSTEM_OPENJPG OFF) elseif(WIN32) set(_init_JACK OFF) elseif(APPLE) set(_init_JACK OFF) set(_init_OPENSUBDIV OFF) - set(_init_SYSTEM_OPENJPG OFF) endif() @@ -209,10 +206,10 @@ option(WITH_INTERNATIONAL "Enable I18N (International fonts and text)" ON) option(WITH_PYTHON "Enable Embedded Python API (only disable for development)" ON) option(WITH_PYTHON_SECURITY "Disables execution of scripts within blend files by default" ON) -mark_as_advanced(WITH_PYTHON) # dont want people disabling this unless they really know what they are doing. +mark_as_advanced(WITH_PYTHON) # don't want people disabling this unless they really know what they are doing. mark_as_advanced(WITH_PYTHON_SECURITY) # some distributions see this as a security issue, rather than have them patch it, make a build option. -option(WITH_PYTHON_SAFETY "Enable internal API error checking to track invalid data to prevent crash on access (at the expense of some effeciency, only enable for development)." OFF) +option(WITH_PYTHON_SAFETY "Enable internal API error checking to track invalid data to prevent crash on access (at the expense of some efficiency, only enable for development)." OFF) mark_as_advanced(WITH_PYTHON_SAFETY) option(WITH_PYTHON_MODULE "Enable building as a python module which runs without a user interface, like running regular blender in background mode (experimental, only enable for development), installs to PYTHON_SITE_PACKAGES (or CMAKE_INSTALL_PREFIX if WITH_INSTALL_PORTABLE is enabled)." OFF) if(APPLE) @@ -224,8 +221,8 @@ if(${CMAKE_VERSION} VERSION_LESS 2.8.8) # add_library OBJECT arg unsupported set(WITH_BUILDINFO OFF) endif() -set(BUILDINFO_OVERRIDE_DATE "" CACHE STRING "Use instead of the current date for reproducable builds (empty string disables this option)") -set(BUILDINFO_OVERRIDE_TIME "" CACHE STRING "Use instead of the current time for reproducable builds (empty string disables this option)") +set(BUILDINFO_OVERRIDE_DATE "" CACHE STRING "Use instead of the current date for reproducible builds (empty string disables this option)") +set(BUILDINFO_OVERRIDE_TIME "" CACHE STRING "Use instead of the current time for reproducible builds (empty string disables this option)") set(CPACK_OVERRIDE_PACKAGENAME "" CACHE STRING "Use instead of the standard packagename (empty string disables this option)") mark_as_advanced(CPACK_OVERRIDE_PACKAGENAME) mark_as_advanced(BUILDINFO_OVERRIDE_DATE) @@ -300,9 +297,6 @@ else() endif() -# (unix defaults to System OpenJPEG On) -option(WITH_SYSTEM_OPENJPEG "Use the operating systems OpenJPEG library" ${_init_SYSTEM_OPENJPG}) - if(UNIX AND NOT APPLE) option(WITH_SYSTEM_EIGEN3 "Use the systems Eigen3 library" OFF) endif() @@ -386,7 +380,9 @@ if(UNIX AND NOT APPLE) endif() option(WITH_PYTHON_INSTALL "Copy system python into the blender install folder" ON) -if(WITH_PYTHON_INSTALL OR (WITH_AUDASPACE AND NOT WITH_SYSTEM_AUDASPACE)) +if(WIN32 OR APPLE) + # Windows and macOS have this bundled with Python libraries. +elseif(WITH_PYTHON_INSTALL OR (WITH_AUDASPACE AND NOT WITH_SYSTEM_AUDASPACE)) set(PYTHON_NUMPY_PATH "" CACHE PATH "Path to python site-packages or dist-packages containing 'numpy' module") mark_as_advanced(PYTHON_NUMPY_PATH) set(PYTHON_NUMPY_INCLUDE_DIRS ${PYTHON_NUMPY_PATH}/numpy/core/include CACHE PATH "Path to the include directory of the numpy module") @@ -410,6 +406,7 @@ option(WITH_CYCLES "Enable Cycles Render Engine" ON) option(WITH_CYCLES_STANDALONE "Build Cycles standalone application" OFF) option(WITH_CYCLES_STANDALONE_GUI "Build Cycles standalone with GUI" OFF) option(WITH_CYCLES_OSL "Build Cycles with OSL support" ${_init_CYCLES_OSL}) +option(WITH_CYCLES_EMBREE "Build Cycles with Embree support" OFF) option(WITH_CYCLES_OPENSUBDIV "Build Cycles with OpenSubdiv support" ${_init_CYCLES_OPENSUBDIV}) option(WITH_CYCLES_CUDA_BINARIES "Build Cycles CUDA binaries" OFF) option(WITH_CYCLES_CUBIN_COMPILER "Build cubins with nvrtc based compiler instead of nvcc" OFF) @@ -572,6 +569,9 @@ if(WIN32) option(WINDOWS_USE_VISUAL_STUDIO_FOLDERS "Organize the visual studio project according to source folders." ON) mark_as_advanced(WINDOWS_USE_VISUAL_STUDIO_FOLDERS) + + option(WINDOWS_PYTHON_DEBUG "Include the files needed for debugging python scripts with visual studio 2017+." OFF) + mark_as_advanced(WINDOWS_PYTHON_DEBUG) endif() # avoid using again @@ -843,7 +843,7 @@ if(WITH_X11) endif() if(WITH_X11_XF86VMODE) - # XXX, why dont cmake make this available? + # XXX, why doesn't cmake make this available? find_library(X11_Xxf86vmode_LIB Xxf86vm ${X11_LIB_SEARCH_PATH}) mark_as_advanced(X11_Xxf86vmode_LIB) if(X11_Xxf86vmode_LIB) @@ -940,7 +940,7 @@ endif() if(SUPPORT_SSE2_BUILD) set(PLATFORM_CFLAGS " ${PLATFORM_CFLAGS} ${COMPILER_SSE2_FLAG}") add_definitions(-D__SSE2__) - if(NOT SUPPORT_SSE_BUILD) # dont double up + if(NOT SUPPORT_SSE_BUILD) # don't double up add_definitions(-D__MMX__) endif() endif() @@ -953,7 +953,7 @@ if(MSVC) # OSX-Note: as we do cross-compiling with specific set architecture, # endianess-detection and auto-setting is counterproductive -# so we just set endianess according CMAKE_OSX_ARCHITECTURES +# so we just set endianness according CMAKE_OSX_ARCHITECTURES elseif(CMAKE_OSX_ARCHITECTURES MATCHES i386 OR CMAKE_OSX_ARCHITECTURES MATCHES x86_64) add_definitions(-D__LITTLE_ENDIAN__) @@ -971,16 +971,11 @@ else() unset(_SYSTEM_BIG_ENDIAN) endif() if(WITH_IMAGE_OPENJPEG) - if(WITH_SYSTEM_OPENJPEG) - # dealt with above - set(OPENJPEG_DEFINES "") - else() - set(OPENJPEG_INCLUDE_DIRS "${CMAKE_SOURCE_DIR}/extern/libopenjpeg") - set(OPENJPEG_DEFINES "-DOPJ_STATIC") - endif() # Special handling of Windows platform where openjpeg is always static. if(WIN32) set(OPENJPEG_DEFINES "-DOPJ_STATIC") + else() + set(OPENJPEG_DEFINES "") endif() endif() @@ -1464,6 +1459,7 @@ elseif(CMAKE_C_COMPILER_ID MATCHES "MSVC") "/wd4305" # truncation from 'type1' to 'type2' "/wd4800" # forcing value to bool 'true' or 'false' "/wd4828" # The file contains a character that is illegal + "/wd4996" # identifier was declared deprecated # errors: "/we4013" # 'function' undefined; assuming extern returning int "/we4133" # incompatible pointer types @@ -1489,14 +1485,14 @@ if(WITH_PYTHON) ) endif() - if(WIN32) - # pass, we have this in an archive to extract + if(WIN32 OR APPLE) + # Windows and macOS have this bundled with Python libraries. elseif((WITH_PYTHON_INSTALL AND WITH_PYTHON_INSTALL_NUMPY) OR (WITH_AUDASPACE AND NOT WITH_SYSTEM_AUDASPACE)) if(("${PYTHON_NUMPY_PATH}" STREQUAL "") OR (${PYTHON_NUMPY_PATH} MATCHES NOTFOUND)) find_python_package(numpy) unset(PYTHON_NUMPY_INCLUDE_DIRS CACHE) set(PYTHON_NUMPY_INCLUDE_DIRS ${PYTHON_NUMPY_PATH}/numpy/core/include CACHE PATH "Path to the include directory of the numpy module") - mark_as_advanced(PYTHON_NUMPY_INCLUDE_DIRS) + mark_as_advanced(PYTHON_NUMPY_INCLUDE_DIRS) endif() endif() @@ -1527,12 +1523,8 @@ if( (CMAKE_C_COMPILER_ID MATCHES "Clang" AND (NOT MSVC)) OR (CMAKE_C_COMPILER_ID MATCHES "Intel") ) - # Use C99 + GNU extensions, works with GCC, Clang, ICC - if(WITH_C11) - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu11") - else() - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99") - endif() + # Use C11 + GNU extensions, works with GCC, Clang, ICC + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu11") endif() # Include warnings first, so its possible to disable them with user defined flags @@ -1680,7 +1672,6 @@ if(FIRST_RUN) info_cfg_option(WITH_MEM_JEMALLOC) info_cfg_option(WITH_MEM_VALGRIND) info_cfg_option(WITH_SYSTEM_GLEW) - info_cfg_option(WITH_SYSTEM_OPENJPEG) info_cfg_text("Image Formats:") info_cfg_option(WITH_OPENIMAGEIO) |