Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 21 additions & 11 deletions F/FFMPEG/FFMPEG/build_tarballs.jl
Original file line number Diff line number Diff line change
Expand Up @@ -12,36 +12,46 @@ products = [
LibraryProduct(["libavdevice", "avdevice"], :libavdevice),
LibraryProduct(["libavfilter", "avfilter"], :libavfilter),
LibraryProduct(["libavformat", "avformat"], :libavformat),
LibraryProduct(["libavresample", "avresample"], :libavresample),
LibraryProduct(["libavutil", "avutil"], :libavutil),
LibraryProduct(["libpostproc", "postproc"], :libpostproc),
LibraryProduct(["libswresample", "swresample"], :libswresample),
LibraryProduct(["libswscale", "swscale"], :libswscale),
]

# Dependencies that must be installed before this package can be built.
# TODO: Theora once it's available
# TODO: Theora once it's available
dependencies = [
HostBuildDependency("YASM_jll"),
BuildDependency("nv_codec_headers_jll"),
Dependency("libass_jll"; compat="0.15.1"),
Dependency("libass_jll"; compat = "0.15.1"),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please remove all the whitespace changes? It makes review needlessly more complicated.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure! Sorry about that, forgot to deactivate format on save

Dependency("libfdk_aac_jll"),
Dependency("FriBidi_jll"),
Dependency("FreeType2_jll"; compat="2.10.4"),
Dependency("FreeType2_jll"; compat = "2.10.4"),
Dependency("LAME_jll"),
Dependency("libvorbis_jll"),
Dependency("libaom_jll"),
Dependency("Ogg_jll"),
BuildDependency("LibVPX_jll"), # We use the static archive
Dependency("x264_jll"; compat="~2021.05.05"),
Dependency("x265_jll"; compat="~3.5"),
Dependency("Bzip2_jll"; compat="1.0.8"),
Dependency("x264_jll"; compat = "~2021.05.05"),
Dependency("x265_jll"; compat = "~3.5"),
Dependency("Bzip2_jll"; compat = "1.0.8"),
Dependency("Zlib_jll"),
Dependency("OpenSSL_jll"; compat="3.0.9"),
Dependency("OpenSSL_jll"; compat = "3.0.9"),
Dependency("Opus_jll"),
Dependency("PCRE2_jll"; compat="10.35"),
Dependency("PCRE2_jll"; compat = "10.35"),
Dependency("Xorg_xproto_jll"),
]

# Build the tarballs, and possibly a `build.jl` as well.
build_tarballs(ARGS, name, version, sources, script(; ffplay=false), platforms, products, dependencies;
julia_compat="1.6", preferred_gcc_version=preferred_gcc_version)
build_tarballs(
ARGS,
name,
version,
sources,
script(; ffplay = false),
platforms,
products,
dependencies;
julia_compat = "1.6",
preferred_gcc_version = preferred_gcc_version,
)
33 changes: 20 additions & 13 deletions F/FFMPEG/common.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,20 @@
using BinaryBuilder, Pkg

name = "FFMPEG"
version_string = "4.4.4" # when patch number is zero, they use X.Y format
version_string = "6.1.1" # when patch number is zero, they use X.Y format
version = VersionNumber(version_string)

# Collection of sources required to build FFMPEG
sources = [
ArchiveSource("https://ffmpeg.org/releases/ffmpeg-$(version_string).tar.xz",
"e80b380d595c809060f66f96a5d849511ef4a76a26b76eacf5778b94c3570309"),
ArchiveSource(
"https://ffmpeg.org/releases/ffmpeg-$(version_string).tar.xz",
"8684f4b00f94b85461884c3719382f1261f0d9eb3d59640a1f4ac0873616f968",
),
## FFmpeg 6.1.1 does not work with macos 10.13 or earlier.
ArchiveSource(
"https://github.com/phracker/MacOSX-SDKs/releases/download/10.15/MacOSX10.13.sdk.tar.xz",
"a3a077385205039a7c6f9e2c98ecdf2a720b2a819da715e03e0630c75782c1e4",
),
]

# Bash recipe for building across all platforms
Expand Down Expand Up @@ -48,15 +55,16 @@ else
export ccARCH="x86_64"
fi

if [[ "${target}" == arm-* ]]; then
export CUDA_ARGS=""
elif [[ "${target}" == *-apple-* ]]; then
export CUDA_ARGS=""
elif [[ "${target}" == *-unknown-freebsd* ]]; then
export CUDA_ARGS=""
else
export CUDA_ARGS="--enable-nvenc --enable-cuda-llvm"
fi
if [[ "${target}" == x86_64-apple-darwin* ]]; then
export MACOSX_DEPLOYMENT_TARGET=10.13
pushd ${WORKSPACE}/srcdir/MacOSX10.*.sdk
rm -rf /opt/${target}/${target}/sys-root/System
cp -a usr/* "/opt/${target}/${target}/sys-root/usr/"
cp -a System "/opt/${target}/${target}/sys-root/"
popd
fi

export CUDA_ARGS=""

EXTRA_FLAGS=()
if [[ "${target}" == *-darwin* ]]; then
Expand Down Expand Up @@ -93,7 +101,6 @@ sed -i 's/cpuflags="-march=$cpu"/cpuflags=""/g' configure
--enable-pic \
--disable-debug \
--disable-doc \
--enable-avresample \
--enable-libaom \
--enable-libass \
--enable-libfdk-aac \
Expand Down