summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Bingner <sam@bingner.com>2019-04-02 23:26:47 -1000
committerSam Bingner <sam@bingner.com>2019-04-09 23:20:35 -1000
commit949842a477d69781ea0a437c3ae6152c01ee38cf (patch)
tree689ab5a7236a4d8b6f626a05ac3648c4c243c863
parentd45ac09ba213985705f64b3043d81e17b30d60ca (diff)
Update x265 to link all versions
-rw-r--r--arch/iphoneos-arm/1443.00/environ.sh1
-rw-r--r--arch/iphoneos-arm/550.58/environ.sh1
-rw-r--r--data/x265/make.sh41
3 files changed, 23 insertions, 20 deletions
diff --git a/arch/iphoneos-arm/1443.00/environ.sh b/arch/iphoneos-arm/1443.00/environ.sh
index 50cc6928f..1639dec91 100644
--- a/arch/iphoneos-arm/1443.00/environ.sh
+++ b/arch/iphoneos-arm/1443.00/environ.sh
@@ -11,3 +11,4 @@ export PKG_objdump="xcrun -sdk iphoneos objdump"
export PKG_ranlib="xcrun -sdk iphoneos ranlib"
export PKG_MCPU=""
export MACOSX_DEPLOYMENT_TARGET=10.13
+export IPHONEOS_DEPLOYMENT_TARGET=11.0
diff --git a/arch/iphoneos-arm/550.58/environ.sh b/arch/iphoneos-arm/550.58/environ.sh
index 9aa15966a..0c3e6776a 100644
--- a/arch/iphoneos-arm/550.58/environ.sh
+++ b/arch/iphoneos-arm/550.58/environ.sh
@@ -1,2 +1,3 @@
export PKG_MCPU="-mthumb -Wl,-segalign,4000"
export MACOSX_DEPLOYMENT_TARGET=10.5
+export IPHONEOS_DEPLOYMENT_TARGET=4.3
diff --git a/data/x265/make.sh b/data/x265/make.sh
index 30cd7f5f2..f0aa4aae7 100644
--- a/data/x265/make.sh
+++ b/data/x265/make.sh
@@ -18,29 +18,30 @@ set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
EOF
-_cmake_args="-DCMAKE_TOOLCHAIN_FILE=$(realpath iphoneos_toolchain.cmake) -DCMAKE_LOCALSTATEDIR='/private/var' -DCMAKE_INSTALL_NAME_DIR='/usr/lib' -DCMAKE_INSTALL_RPATH='/usr/' -DCMAKE_OSX_SYSROOT='${PKG_ROOT}' -DCMAKE_INSTALL_PREFIX='/usr/'"
-_args="-DLINKED_10BIT=ON -DLINKED_12BIT=ON -DEXTRA_LINK_FLAGS=-L. -DEXTRA_LIB=x265_main10.a;x265_main12.a"
-_high_bit="-DHIGH_BIT_DEPTH=ON -DEXPORT_C_API=OFF -DENABLE_SHARED=OFF -DENABLE_CLI=OFF"
+# WTF cmake
+export MACOSX_DEPLOYMENT_TARGET="${IPHONEOS_DEPLOYMENT_TARGET}"
-mkdir 10bit 12bit 8bit
+_cmake_args=(-DCMAKE_TOOLCHAIN_FILE=$(realpath iphoneos_toolchain.cmake) -DCMAKE_INSTALL_NAME_DIR=/usr/lib -DCMAKE_INSTALL_RPATH=/usr -DCMAKE_OSX_SYSROOT="${PKG_ROOT}" -DCMAKE_INSTALL_PREFIX=/usr)
+_args=(-DENABLE_STATIC=OFF -DEXTRA_LIB="x265_main10.a;x265_main12.a" -DLINKED_10BIT=ON -DLINKED_12BIT=ON -DEXTRA_LINK_FLAGS="-Lx265-10bit -Lx265-12bit")
+_high_bit=(-DHIGH_BIT_DEPTH=ON -DEXPORT_C_API=OFF -DENABLE_SHARED=OFF -DENABLE_CLI=OFF)
-pushd 10bit
- cmake ../source ${_cmake_args} ${_high_bit}
- make -j4
- mv libx265.a ../8bit/libx265_main10.a
+cd build
+mkdir x265-10bit x265-12bit || true
+
+pushd x265-10bit
+ cmake ../../source "${_cmake_args[@]}" "${_high_bit[@]}"
+ make -j16
+ mv libx265.a libx265_main10.a
popd &>/dev/null
-pushd 12bit
- cmake ../source ${_cmake_args} -DMAIN12=ON ${_high_bit}
- make -j4
- mv libx265.a ../8bit/libx265_main12.a
+pushd x265-12bit
+ cmake ../../source "${_cmake_args[@]}" -DMAIN12=ON "${_high_bit[@]}"
+ make -j16
+ mv libx265.a libx265_main12.a
popd &>/dev/null
-cd 8bit
- cmake ../source ${_cmake_args} ${args}
- make -j4
- mv libx265.a libx265_main.a
- ${PKG_TARG}-libtool -static -o libx265.a libx265_main.a libx265_main10.a libx265_main12.a || \
- libtool -static -o libx265.a libx265_main.a libx265_main10.a libx265_main12.a
- # Try host's libtool if target's doesn't exist.
- pkg:install
+echo cmake ../source "${_cmake_args[@]}" "${_args[@]}"
+cmake ../source "${_cmake_args[@]}" "${_args[@]}"
+make -j16
+pkg:install
+pkg: rm /usr/lib/libx265.a