[Bf-blender-cvs] [caefe4943b4] master: [deps_build/macOS] Fix FFMPEG & VPX configure command

Arto Kitula noreply at git.blender.org
Tue Aug 15 12:07:44 CEST 2017


Commit: caefe4943b4d2c8424e00df4a9d22487fca4bcd7
Author: Arto Kitula
Date:   Tue Aug 15 12:26:33 2017 +0300
Branches: master
https://developer.blender.org/rBcaefe4943b4d2c8424e00df4a9d22487fca4bcd7

[deps_build/macOS] Fix FFMPEG & VPX configure command

FFMPEG & VPX don't handle target with --build parameter, so we need to make sure use of plain configure command

Reviewed by: Brecht Van Lommel
Differential Revision: http://developer.blender.org/D2791

===================================================================

M	build_files/build_environment/cmake/ffmpeg.cmake
M	build_files/build_environment/cmake/options.cmake
M	build_files/build_environment/cmake/vpx.cmake

===================================================================

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/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/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




More information about the Bf-blender-cvs mailing list