diff options
Diffstat (limited to 'build_files/build_environment')
6 files changed, 42 insertions, 12 deletions
diff --git a/build_files/build_environment/cmake/ffmpeg.cmake b/build_files/build_environment/cmake/ffmpeg.cmake index 3f9091b5ee3..2a45849acf5 100644 --- a/build_files/build_environment/cmake/ffmpeg.cmake +++ b/build_files/build_environment/cmake/ffmpeg.cmake @@ -39,6 +39,13 @@ else() --enable-libopenjpeg) endif() +if(APPLE) + set(FFMPEG_EXTRA_FLAGS + ${FFMPEG_EXTRA_FLAGS} + --target-os=darwin + ) +endif() + ExternalProject_Add(external_ffmpeg URL ${FFMPEG_URI} DOWNLOAD_DIR ${DOWNLOAD_DIR} @@ -46,7 +53,7 @@ ExternalProject_Add(external_ffmpeg PREFIX ${BUILD_DIR}/ffmpeg CONFIGURE_COMMAND ${CONFIGURE_ENV_NO_PERL} && cd ${BUILD_DIR}/ffmpeg/src/external_ffmpeg/ && - ${FFMPEG_ENV} ${CONFIGURE_COMMAND} ${FFMPEG_EXTRA_FLAGS} + ${FFMPEG_ENV} ${CONFIGURE_COMMAND_NO_TARGET} ${FFMPEG_EXTRA_FLAGS} --disable-lzma --disable-avfilter --disable-vdpau diff --git a/build_files/build_environment/cmake/numpy.cmake b/build_files/build_environment/cmake/numpy.cmake index 51cb30799a7..ab196dc5eec 100644 --- a/build_files/build_environment/cmake/numpy.cmake +++ b/build_files/build_environment/cmake/numpy.cmake @@ -32,8 +32,9 @@ set(NUMPY_POSTFIX) if(WIN32) set(NUMPY_INSTALL - ${CMAKE_COMMAND} -E chdir "${BUILD_DIR}/numpy/src/external_numpy/build/lib.${PYTHON_ARCH2}-3.5${NUMPY_DIR_POSTFIX}" - ${CMAKE_COMMAND} -E tar "cfvz" "${LIBDIR}/python35_numpy_${NUMPY_SHORT_VERSION}${NUMPY_ARCHIVE_POSTFIX}.tar.gz" "." + ${CMAKE_COMMAND} -E copy_directory "${BUILD_DIR}/python/src/external_python/run/lib/site-packages/numpy/core/include/numpy" "${LIBDIR}/python/include/python3.5/numpy" && + ${CMAKE_COMMAND} -E chdir "${BUILD_DIR}/numpy/src/external_numpy/build/lib.${PYTHON_ARCH2}-3.5${NUMPY_DIR_POSTFIX}" + ${CMAKE_COMMAND} -E tar "cfvz" "${LIBDIR}/python35_numpy_${NUMPY_SHORT_VERSION}${NUMPY_ARCHIVE_POSTFIX}.tar.gz" "." ) else() set(NUMPY_INSTALL @@ -49,7 +50,7 @@ ExternalProject_Add(external_numpy PATCH_COMMAND ${PATCH_CMD} --verbose -p 1 -N -d ${BUILD_DIR}/numpy/src/external_numpy < ${PATCH_DIR}/numpy.diff CONFIGURE_COMMAND "" LOG_BUILD 1 - BUILD_COMMAND ${PYTHON_BINARY} ${BUILD_DIR}/numpy/src/external_numpy/setup.py build ${NUMPY_BUILD_OPTION} + BUILD_COMMAND ${PYTHON_BINARY} ${BUILD_DIR}/numpy/src/external_numpy/setup.py build ${NUMPY_BUILD_OPTION} install INSTALL_COMMAND ${NUMPY_INSTALL} ) diff --git a/build_files/build_environment/cmake/options.cmake b/build_files/build_environment/cmake/options.cmake index 5618fc1255d..465ca3c034c 100644 --- a/build_files/build_environment/cmake/options.cmake +++ b/build_files/build_environment/cmake/options.cmake @@ -108,6 +108,7 @@ if(WIN32) ) set(CONFIGURE_COMMAND sh ./configure) + set(CONFIGURE_COMMAND_NO_TARGET ${CONFIGURE_COMMAND}) else() set(PATCH_CMD patch) set(LIBEXT ".a") @@ -163,6 +164,7 @@ else() ) set(CONFIGURE_ENV_NO_PERL ${CONFIGURE_ENV}) set(CONFIGURE_COMMAND ./configure ${PLATFORM_BUILD_TARGET}) + set(CONFIGURE_COMMAND_NO_TARGET ./configure) endif() set(DEFAULT_CMAKE_FLAGS diff --git a/build_files/build_environment/cmake/osl.cmake b/build_files/build_environment/cmake/osl.cmake index 97b86c39baa..5ddb981c604 100644 --- a/build_files/build_environment/cmake/osl.cmake +++ b/build_files/build_environment/cmake/osl.cmake @@ -21,9 +21,9 @@ if(WIN32) set(OSL_FLEX_BISON -DFLEX_EXECUTABLE=${LIBDIR}/flexbison/win_flex.exe -DFLEX_EXTRA_OPTIONS="--wincompat" -DBISON_EXECUTABLE=${LIBDIR}/flexbison/win_bison.exe) set(OSL_OPENIMAGEIO_LIBRARY "${LIBDIR}/openimageio/lib/${LIBPREFIX}OpenImageIO${LIBEXT};${LIBDIR}/openimageio/lib/${LIBPREFIX}OpenImageIO_Util${LIBEXT};${LIBDIR}/png/lib/libpng16${LIBEXT};${LIBDIR}/jpg/lib/${LIBPREFIX}jpeg${LIBEXT};${LIBDIR}/tiff/lib/${LIBPREFIX}tiff${LIBEXT};${LIBDIR}/openexr/lib/${LIBPREFIX}IlmImf-2_2${LIBEXT}") if("${CMAKE_SIZEOF_VOID_P}" EQUAL "4") - set(OSL_SIMD_FLAGS -DOIIO_SIMD=0) + set(OSL_SIMD_FLAGS -DOIIO_NOSIMD=1 -DOIIO_SIMD=0) else() - set(OSL_SIMD_FLAGS -DOIIO_SIMD=sse2) + set(OSL_SIMD_FLAGS -DOIIO_NOSIMD=1 -DOIIO_SIMD=sse2) endif() else() set(OSL_CMAKE_CXX_STANDARD_LIBRARIES) diff --git a/build_files/build_environment/cmake/vpx.cmake b/build_files/build_environment/cmake/vpx.cmake index 6569708cb5f..9d155be1c6c 100644 --- a/build_files/build_environment/cmake/vpx.cmake +++ b/build_files/build_environment/cmake/vpx.cmake @@ -23,7 +23,11 @@ if(WIN32) set(VPX_EXTRA_FLAGS --target=x86-win32-gcc) endif() else() - set(VPX_EXTRA_FLAGS --target=generic-gnu) + if(APPLE) + set(VPX_EXTRA_FLAGS --target=x86_64-darwin13-gcc) + else() + set(VPX_EXTRA_FLAGS --target=generic-gnu) + endif() endif() ExternalProject_Add(external_vpx @@ -33,7 +37,7 @@ ExternalProject_Add(external_vpx PREFIX ${BUILD_DIR}/vpx CONFIGURE_COMMAND ${CONFIGURE_ENV} && cd ${BUILD_DIR}/vpx/src/external_vpx/ && - ${CONFIGURE_COMMAND} --prefix=${LIBDIR}/vpx + ${CONFIGURE_COMMAND_NO_TARGET} --prefix=${LIBDIR}/vpx --disable-shared --enable-static --disable-install-bins diff --git a/build_files/build_environment/patches/python_runtime_vc2013.diff b/build_files/build_environment/patches/python_runtime_vc2013.diff index 8177f735c92..186d2b36c07 100644 --- a/build_files/build_environment/patches/python_runtime_vc2013.diff +++ b/build_files/build_environment/patches/python_runtime_vc2013.diff @@ -1,6 +1,18 @@ ---- _msvccompiler.py 2016-08-12 10:44:32 -0600 -+++ _msvccompiler.py 2016-08-12 10:47:29 -0600 -@@ -246,8 +246,8 @@ +--- _msvccompiler.py.orig 2017-05-20 19:31:45 -0600 ++++ _msvccompiler.py 2017-06-10 10:05:38 -0600 +@@ -222,9 +222,9 @@ + # use /MT[d] to build statically, then switch from libucrt[d].lib to ucrt[d].lib + # later to dynamically link to ucrtbase but not vcruntime. + self.compile_options = [ +- '/nologo', '/Ox', '/W3', '/GL', '/DNDEBUG' ++ '/nologo', '/Ox', '/W3', '/GL', '/DNDEBUG' , '/MD' + ] +- self.compile_options.append('/MD' if self._vcruntime_redist else '/MT') ++ #self.compile_options.append('/MD' if self._vcruntime_redist else '/MT') + + self.compile_options_debug = [ + '/nologo', '/Od', '/MDd', '/Zi', '/W3', '/D_DEBUG' +@@ -233,11 +233,11 @@ ldflags = [ '/nologo', '/INCREMENTAL:NO', '/LTCG' ] @@ -10,4 +22,8 @@ + # ldflags.extend(('/nodefaultlib:libucrt.lib', 'ucrt.lib')) ldflags_debug = [ - '/nologo', '/INCREMENTAL:NO', '/LTCG', '/DEBUG:FULL' +- '/nologo', '/INCREMENTAL:NO', '/LTCG', '/DEBUG:FULL' ++ '/nologo', '/INCREMENTAL:NO', '/LTCG' + ] + + self.ldflags_exe = [*ldflags, '/MANIFEST:EMBED,ID=1'] |