From bc054522e8b22cce12735b2adb7b89ae314c7794 Mon Sep 17 00:00:00 2001 From: Daniel Stankewitz Date: Tue, 5 Dec 2017 14:14:52 +0100 Subject: [PATCH] Update build.sh Doing a multilib build of x265 now (8, 10 and 12 bits) --- build.sh | 27 ++++++++++++++++++++------- 1 file changed, 20 insertions(+), 7 deletions(-) diff --git a/build.sh b/build.sh index 00a895e..b82492f 100644 --- a/build.sh +++ b/build.sh @@ -21,7 +21,7 @@ function get_source_ffmpeg { git clone https://git.ffmpeg.org/ffmpeg.git $SRC/ffmpeg fi cd $SRC/ffmpeg - git checkout master + git checkout release/3.4 git pull cd ../.. } @@ -70,13 +70,26 @@ function compile_x264 { function compile_x265 { cd $SRC/x265/build/vc15-x86_64 - rm -rf work - mkdir work - cd work - cmake -G "Visual Studio 15 Win64" ../../../source -DCMAKE_INSTALL_PREFIX=$BUILD -DENABLE_SHARED=OFF -DENABLE_CLI=OFF + rm -rf work* + mkdir work work10 work12 + # 12bit + cd work12 + cmake -G "Visual Studio 15 Win64" ../../../source -DHIGH_BIT_DEPTH=ON -DEXPORT_C_API=OFF -DENABLE_SHARED=OFF -DENABLE_CLI=OFF -DMAIN12=ON + MSBuild.exe /property:Configuration="$MSBUILD_CONFIG" x265-static.vcxproj + cp $MSBUILD_CONFIG/x265-static.lib ../work/x265_12bit.lib + # 10bit + cd ../work10 + cmake -G "Visual Studio 15 Win64" ../../../source -DHIGH_BIT_DEPTH=ON -DEXPORT_C_API=OFF -DENABLE_SHARED=OFF -DENABLE_CLI=OFF + MSBuild.exe /property:Configuration="$MSBUILD_CONFIG" x265-static.vcxproj + cp $MSBUILD_CONFIG/x265-static.lib ../work/x265_10bit.lib + # 8bit - main + cd ../work + cmake -G "Visual Studio 15 Win64" ../../../source -DCMAKE_INSTALL_PREFIX=$BUILD -DENABLE_SHARED=OFF -DENABLE_CLI=OFF -DEXTRA_LIB="x265_10bit.lib;x265_12bit.lib" -DLINKED_10BIT=ON -DLINKED_12BIT=ON #-DSTATIC_LINK_CRT=ON MSBuild.exe /property:Configuration="$MSBUILD_CONFIG" x265-static.vcxproj - cp $MSBUILD_CONFIG/x265-static.lib $BUILD/lib/x265.lib + cp $MSBUILD_CONFIG/x265-static.lib ./x265_main.lib + LIB.EXE /ignore:4006 /ignore:4221 /OUT:x265.lib x265_main.lib x265_10bit.lib x265_12bit.lib + cp x265.lib $BUILD/lib/x265.lib cp x265.pc $BUILD/lib/pkgconfig/x265.pc cp x265_config.h $BUILD/include/ cp ../../../source/x265.h $BUILD/include/ @@ -91,7 +104,7 @@ function compile_ffmpeg { elif [ "$MODE" == "release" ]; then CCFLAGS=-MD fi - PKG_CONFIG_PATH=$BUILD/lib/pkgconfig:$PKG_CONFIG_PATH ./configure --toolchain=msvc --extra-cflags="$CCFLAGS" --prefix=$BUILD --pkg-config-flags="--static" --disable-programs --disable-shared --enable-static --enable-gpl --enable-runtime-cpudetect --disable-hwaccels --disable-devices --disable-network --enable-libx264 --enable-libx265 + PKG_CONFIG_PATH=$BUILD/lib/pkgconfig:$PKG_CONFIG_PATH ./configure --toolchain=msvc --extra-cflags="$CCFLAGS" --prefix=$BUILD --pkg-config-flags="--static" --disable-programs --disable-shared --enable-static --enable-gpl --enable-runtime-cpudetect --disable-hwaccels --disable-devices --disable-network --enable-avisynth --enable-libx264 --enable-libx265 make make install }