mirror of
https://github.com/BtbN/FFmpeg-Builds.git
synced 2025-06-12 13:27:38 +02:00
37
scripts.d/50-aribb24/25-libpng.sh
Executable file
37
scripts.d/50-aribb24/25-libpng.sh
Executable file
@ -0,0 +1,37 @@
|
||||
#!/bin/bash
|
||||
|
||||
LIBPNG_REPO="https://github.com/glennrp/libpng.git"
|
||||
LIBPNG_COMMIT="a37d4836519517bdce6cb9d956092321eca3e73b"
|
||||
|
||||
ffbuild_enabled() {
|
||||
return 0
|
||||
}
|
||||
|
||||
ffbuild_dockerbuild() {
|
||||
git-mini-clone "$LIBPNG_REPO" "$LIBPNG_COMMIT" libpng
|
||||
cd libpng
|
||||
|
||||
autoreconf -i
|
||||
|
||||
local myconf=(
|
||||
--prefix="$FFBUILD_PREFIX"
|
||||
--disable-shared
|
||||
--enable-static
|
||||
--with-pic
|
||||
)
|
||||
|
||||
if [[ $TARGET == win* || $TARGET == linux* ]]; then
|
||||
myconf+=(
|
||||
--host="$FFBUILD_TOOLCHAIN"
|
||||
)
|
||||
else
|
||||
echo "Unknown target"
|
||||
return -1
|
||||
fi
|
||||
|
||||
export CPPFLAGS="$CPPFLAGS -I$FFBUILD_PREFIX/include"
|
||||
|
||||
./configure "${myconf[@]}"
|
||||
make -j$(nproc)
|
||||
make install
|
||||
}
|
56
scripts.d/50-aribb24/50-libaribb24.sh
Executable file
56
scripts.d/50-aribb24/50-libaribb24.sh
Executable file
@ -0,0 +1,56 @@
|
||||
#!/bin/bash
|
||||
|
||||
ARIBB24_REPO="https://github.com/nkoriyama/aribb24.git"
|
||||
ARIBB24_COMMIT="5e9be272f96e00f15a2f3c5f8ba7e124862aec38"
|
||||
|
||||
ffbuild_enabled() {
|
||||
return 0
|
||||
}
|
||||
|
||||
ffbuild_dockerstage() {
|
||||
to_df "RUN --mount=src=${SELF},dst=/stage.sh --mount=src=patches/aribb24,dst=/patches run_stage /stage.sh"
|
||||
}
|
||||
|
||||
ffbuild_dockerbuild() {
|
||||
git-mini-clone "$ARIBB24_REPO" "$ARIBB24_COMMIT" aribb24
|
||||
cd aribb24
|
||||
|
||||
for patch in /patches/*.patch; do
|
||||
echo "Applying $patch"
|
||||
git am < "$patch"
|
||||
done
|
||||
|
||||
# Library switched to LGPL on master, but didn't bump version since.
|
||||
# FFmpeg checks for >1.0.3 to allow LGPL builds.
|
||||
sed -i 's/1.0.3/1.0.4/' configure.ac
|
||||
|
||||
autoreconf -i
|
||||
|
||||
local myconf=(
|
||||
--prefix="$FFBUILD_PREFIX"
|
||||
--disable-shared
|
||||
--enable-static
|
||||
--with-pic
|
||||
)
|
||||
|
||||
if [[ $TARGET == win* || $TARGET == linux* ]]; then
|
||||
myconf+=(
|
||||
--host="$FFBUILD_TOOLCHAIN"
|
||||
)
|
||||
else
|
||||
echo "Unknown target"
|
||||
return -1
|
||||
fi
|
||||
|
||||
./configure "${myconf[@]}"
|
||||
make -j$(nproc)
|
||||
make install
|
||||
}
|
||||
|
||||
ffbuild_configure() {
|
||||
echo --enable-libaribb24
|
||||
}
|
||||
|
||||
ffbuild_unconfigure() {
|
||||
echo --disable-libaribb24
|
||||
}
|
Reference in New Issue
Block a user