[ffmpeg] Update to 4.3.1 (#13365)

Co-authored-by: Lily <47812810+LilyWangL@users.noreply.github.com>
Co-authored-by: wangli28 <wangli28@beyondsoft.com>
Co-authored-by: Billy Robert O'Neal III <bion@microsoft.com>
This commit is contained in:
Matthew Oliver 2020-10-07 18:23:23 +11:00 committed by GitHub
parent 7dc0049439
commit 72d98524e3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
13 changed files with 50 additions and 46 deletions

View File

@ -24,12 +24,7 @@ set(CMAKE_DEBUG_POSTFIX d)
option(BUILD_TOOLS "Build and install tools" ON)
set(TOOLS_INSTALLDIR "bin" CACHE STRING "Target directory for installed tools")
find_library(AVCODEC_LIB avcodec)
find_library(AVUTIL_LIB avutil)
find_library(AVDEVICE_LIB avdevice)
find_library(AVFILTER_LIB avfilter)
find_library(AVFORMAT_LIB avformat)
find_library(SWRESAMPLE_LIB swresample)
find_package(FFmpeg COMPONENTS avcodec avutil avdevice avfilter avformat swresample REQUIRED)
find_package(BZip2 REQUIRED)
find_package(LibLZMA REQUIRED)
find_package(SndFile REQUIRED)
@ -42,17 +37,9 @@ set_source_files_properties(src/io/sink_wavwrite.c PROPERTIES COMPILE_FLAGS /FIW
add_library(aubio ${SOURCES})
target_link_libraries(aubio PUBLIC
SndFile::sndfile
${AVCODEC_LIB}
${AVUTIL_LIB}
${AVDEVICE_LIB}
${AVFILTER_LIB}
${AVFORMAT_LIB}
${SWRESAMPLE_LIB}
${FFMPEG_LIBRARIES}
BZip2::BZip2
${LIBLZMA_LIBRARIES}
ws2_32.lib
Secur32.lib
bcrypt.lib
)
if(BUILD_TOOLS)

View File

@ -1,6 +1,6 @@
Source: aubio
Version: 0.4.9
Port-Version: 2
Port-Version: 3
Homepage: https://github.com/aubio/aubio
Description: Aubio is a tool designed for the extraction of annotations from audio signals. Its features include segmenting a sound file before each of its attacks, performing pitch detection, tapping the beat and producing midi streams from live audio.
Build-Depends: ffmpeg, libsndfile, libogg, libflac, libvorbis, bzip2, liblzma

View File

@ -2,17 +2,17 @@ diff --git a/configure b/configure
index 3bdcfc6..00b2f13 100644
--- a/configure
+++ b/configure
@@ -6251,7 +6251,8 @@ if enabled libmfx; then
enabled libmfx && { check_pkg_config libmfx libmfx "mfx/mfxvideo.h" MFXInit ||
{ require libmfx "mfx/mfxvideo.h" MFXInit "-llibmfx $advapi32_extralibs" && warn "using libmfx without pkg-config"; } }
@@ -6351,7 +6351,8 @@ if enabled libmfx; then
fi
enabled libmodplug && require_pkg_config libmodplug libmodplug libmodplug/modplug.h ModPlug_Load
-enabled libmp3lame && require "libmp3lame >= 3.98.3" lame/lame.h lame_set_VBR_quality -lmp3lame $libm_extralibs
+enabled libmp3lame && { check_lib libmp3lame lame/lame.h lame_set_VBR_quality -lmp3lame $libm_extralibs ||
+ require libmp3lame lame/lame.h lame_set_VBR_quality -llibmp3lame-static -llibmpghip-static $libm_extralibs; }
enabled libmysofa && { check_pkg_config libmysofa libmysofa mysofa.h mysofa_load ||
require libmysofa mysofa.h mysofa_load -lmysofa $zlib_extralibs; }
enabled libmysofa && { check_pkg_config libmysofa libmysofa mysofa.h mysofa_neighborhood_init_withstepdefine ||
require libmysofa mysofa.h mysofa_neighborhood_init_withstepdefine -lmysofa $zlib_extralibs; }
enabled libnpp && { check_lib libnpp npp.h nppGetLibVersion -lnppig -lnppicc -lnppc -lnppidei ||
@@ -6292,7 +6293,7 @@ if enabled debug_configure; then
@@ -6392,7 +6393,7 @@ if enabled debug_configure; then
else
enabled libsnappy && require libsnappy snappy-c.h snappy_compress -lsnappy -lstdc++
fi
@ -21,7 +21,7 @@ index 3bdcfc6..00b2f13 100644
enabled libssh && require_pkg_config libssh libssh libssh/sftp.h sftp_init
enabled libspeex && require_pkg_config libspeex speex speex/speex.h speex_decoder_init
enabled libsrt && require_pkg_config libsrt "srt >= 1.3.0" srt/srt.h srt_socket
@@ -6360,6 +6361,8 @@ enabled openal && { { for al_extralibs in "${OPENAL_LIBS}" "-lopenal"
@@ -6460,6 +6461,8 @@ enabled openal && { { for al_extralibs in "${OPENAL_LIBS}" "-lopenal"
enabled opencl && { check_pkg_config opencl OpenCL CL/cl.h clEnqueueNDRangeKernel ||
check_lib opencl OpenCL/cl.h clEnqueueNDRangeKernel -Wl,-framework,OpenCL ||
check_lib opencl CL/cl.h clEnqueueNDRangeKernel -lOpenCL ||
@ -30,7 +30,7 @@ index 3bdcfc6..00b2f13 100644
die "ERROR: opencl not found"; } &&
{ test_cpp_condition "OpenCL/cl.h" "defined(CL_VERSION_1_2)" ||
test_cpp_condition "CL/cl.h" "defined(CL_VERSION_1_2)" ||
@@ -6379,6 +6382,7 @@ enabled openssl && { check_pkg_config openssl openssl openssl/ssl.h OP
@@ -6479,6 +6482,7 @@ enabled openssl && { check_pkg_config openssl openssl openssl/ssl.h OP
check_lib openssl openssl/ssl.h SSL_library_init -lssl -lcrypto ||
check_lib openssl openssl/ssl.h SSL_library_init -lssl32 -leay32 ||
check_lib openssl openssl/ssl.h SSL_library_init -lssl -lcrypto -lws2_32 -lgdi32 ||

View File

@ -10,7 +10,7 @@ index 34a2e644c4..0ea64bd306 100755
+enabled libx265 && { check_pkg_config libx265 x265 x265.h x265_api_get ||
+ { require libx265 x265.h x265_api_get "-lx265 $pthreads_extralibs $libm_extralibs -ldl -lstdc++ -lgcc_s -lgcc -lrt -lnuma" &&
+ warn "using libx265 without pkg-config"; } } &&
require_cpp_condition libx265 x265.h "X265_BUILD >= 68"
require_cpp_condition libx265 x265.h "X265_BUILD >= 70"
enabled libxavs && require libxavs "stdint.h xavs.h" xavs_encoder_encode "-lxavs $pthreads_extralibs $libm_extralibs"
enabled libxavs2 && require_pkg_config libxavs2 "xavs2 >= 1.3.0" "stdint.h xavs2.h" xavs2_api_get

View File

@ -3,11 +3,11 @@ index 2be953f7e7..e075949ffc 100755
--- a/configure
+++ b/configure
@@ -6497,6 +6497,7 @@ enabled omx_rpi && { test_code cc OMX_Core.h OMX_IndexConfigBrcmVideoR
die "ERROR: OpenMAX IL headers not found"; } && enable omx
enabled omx && require_headers OMX_Core.h
enabled openssl && { check_pkg_config openssl openssl openssl/ssl.h OPENSSL_init_ssl ||
check_pkg_config openssl openssl openssl/ssl.h SSL_library_init ||
+ check_lib openssl openssl/ssl.h OPENSSL_init_ssl -lssl -lcrypto $pthreads_extralibs -ldl ||
check_lib openssl openssl/ssl.h OPENSSL_init_ssl -lssl -lcrypto ||
check_lib openssl openssl/ssl.h SSL_library_init -lssl -lcrypto ||
check_lib openssl openssl/ssl.h SSL_library_init -lssl32 -leay32 ||
check_lib openssl openssl/ssl.h SSL_library_init -lssl -lcrypto -lws2_32 -lgdi32 ||

View File

@ -1,6 +1,5 @@
Source: ffmpeg
Version: 4.2
Port-Version: 26
Version: 4.3.1
Homepage: https://ffmpeg.org
Description: a library to decode, encode, transcode, mux, demux, stream, filter and play pretty much anything that humans and machines have created.
FFmpeg is the leading multimedia framework, able to decode, encode, transcode, mux, demux, stream, filter and play pretty much anything that humans and machines have created. It supports the most obscure ancient formats up to the cutting edge. No matter if they were designed by some standards committee, the community or a corporation. It is also highly portable: FFmpeg compiles, runs, and passes our testing infrastructure FATE across Linux, Mac OS X, Microsoft Windows, the BSDs, Solaris, etc. under a wide variety of build environments, machine architectures, and configurations.

View File

@ -68,13 +68,14 @@ if(@ENABLE_LAME@)
get_target_property(LAME_LIBRARY_RELEASE mp3lame::mp3lame IMPORTED_LOCATION_RELEASE)
get_target_property(LAME_LIBRARY_DEBUG mp3lame::mp3lame IMPORTED_LOCATION_DEBUG)
list(APPEND FFMPEG_PLATFORM_DEPENDENT_LIBS "$<$<CONFIG:Debug>:${LAME_LIBRARY_DEBUG}>$<$<NOT:$<CONFIG:Debug>>:${LAME_LIBRARY_RELEASE}>")
get_target_property(LAMEMPG_LIBRARY_RELEASE mp3lame::mpghip IMPORTED_LOCATION_RELEASE)
get_target_property(LAMEMPG_LIBRARY_DEBUG mp3lame::mpghip IMPORTED_LOCATION_DEBUG)
list(APPEND FFMPEG_PLATFORM_DEPENDENT_LIBS "$<$<CONFIG:Debug>:${LAMEMPG_LIBRARY_DEBUG}>$<$<NOT:$<CONFIG:Debug>>:${LAMEMPG_LIBRARY_RELEASE}>")
endif()
if(@ENABLE_OPENCL@)
find_dependency(OpenCL)
get_target_property(OPENCL_LIBRARY_RELEASE OpenCL::OpenCL IMPORTED_LOCATION_RELEASE)
get_target_property(OPENCL_LIBRARY_DEBUG OpenCL::OpenCL IMPORTED_LOCATION_DEBUG)
list(APPEND FFMPEG_PLATFORM_DEPENDENT_LIBS "$<$<CONFIG:Debug>:${OPENCL_LIBRARY_DEBUG}>$<$<NOT:$<CONFIG:Debug>>:${OPENCL_LIBRARY_RELEASE}>")
list(APPEND FFMPEG_PLATFORM_DEPENDENT_LIBS ${OpenCL_LIBRARIES})
endif()
if(@ENABLE_OPENSSL@)
@ -96,8 +97,13 @@ endif()
if(@ENABLE_SDL2@)
find_dependency(SDL2)
get_target_property(SDL2_LIBRARY_RELEASE SDL2::SDL2 IMPORTED_LOCATION_RELEASE)
get_target_property(SDL2_LIBRARY_DEBUG SDL2::SDL2 IMPORTED_LOCATION_DEBUG)
if(TARGET SDL2::SDL2-static)
get_target_property(SDL2_LIBRARY_RELEASE SDL2::SDL2-static IMPORTED_LOCATION_RELEASE)
get_target_property(SDL2_LIBRARY_DEBUG SDL2::SDL2-static IMPORTED_LOCATION_DEBUG)
else()
get_target_property(SDL2_LIBRARY_RELEASE SDL2::SDL2 IMPORTED_LOCATION_RELEASE)
get_target_property(SDL2_LIBRARY_DEBUG SDL2::SDL2 IMPORTED_LOCATION_DEBUG)
endif()
list(APPEND FFMPEG_PLATFORM_DEPENDENT_LIBS "$<$<CONFIG:Debug>:${SDL2_LIBRARY_DEBUG}>$<$<NOT:$<CONFIG:Debug>>:${SDL2_LIBRARY_RELEASE}>")
endif()
@ -183,7 +189,7 @@ endif()
# Platform dependent libraries required by FFMPEG
if(WIN32)
if(NOT CYGWIN)
list(APPEND FFMPEG_PLATFORM_DEPENDENT_LIBS wsock32 ws2_32 secur32 bcrypt strmiids Vfw32 Shlwapi)
list(APPEND FFMPEG_PLATFORM_DEPENDENT_LIBS wsock32 ws2_32 secur32 bcrypt strmiids Vfw32 Shlwapi mfplat mfuuid)
endif()
else()
list(APPEND FFMPEG_PLATFORM_DEPENDENT_LIBS m)

View File

@ -1,8 +1,8 @@
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO ffmpeg/ffmpeg
REF n4.2
SHA512 9fa56364696f91e2bf4287954d26f0c35b3f8aad241df3fbd3c9fc617235d8c83b28ddcac88436383b2eb273f690322e6f349e2f9c64d02f0058a4b76fa55035
REF n4.3.1
SHA512 9d533f6db97e8eccb77d78d0b55112ce039580b570d2a98c4204199abe5a4b0f448c44b30048329f6c912579f8ff48385d5100f9e484709b9fd8f4b3935b5031
HEAD_REF master
PATCHES
0001-create-lib-libraries.patch

View File

@ -1,6 +1,5 @@
Source: ffnvcodec
Version: 9.1.23.1
Port-Version: 4
Version: 10.0.26.0
Homepage: https://github.com/FFmpeg/nv-codec-headers
Description: FFmpeg version of Nvidia Codec SDK headers.
Supports: windows|linux

View File

@ -2,8 +2,8 @@
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO FFmpeg/nv-codec-headers
REF 4a0bbfd58724d6d19851cd8a6f7a9098dde9ab77 # 9.1.23.1
SHA512 39b643c6925558428f2e814fc3441878a906f324163396b8c6139ce48f62308c3dc2416b9c995eaed890338919ca0dfc9437fbb6b6d078f7a6f1b9675104c223
REF 5ee2ae591f74f53bd6028344f8690f1558a1f17a # 10.0.26.0
SHA512 f9d40a44f85016f0f76c7f630c3defb2e94858b43ae714adae546842c2801f51358b7c2b3326952e7aeb25f5b1611af4eee3024f495eaaaecbfd31851cc7edca
HEAD_REF master
)
@ -12,7 +12,7 @@ vcpkg_from_github(
# ====================================================
# Windows
if(NOT VCPKG_CMAKE_SYSTEM_NAME OR VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
if(VCPKG_TARGET_IS_WINDOWS)
set(BUILD_SCRIPT ${CMAKE_CURRENT_LIST_DIR}\\build.sh)
vcpkg_acquire_msys(MSYS_ROOT PACKAGES make pkg-config)
set(BASH ${MSYS_ROOT}/usr/bin/bash.exe)

View File

@ -0,0 +1,15 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index f377c428..07530304 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -60,6 +60,9 @@ message(STATUS "Configuring ${PROJECT_NAME} ${PROJECT_VERSION}")
# Find math library
check_library_exists(m floor "" HAVE_LIBM)
+if(HAVE_LIBM)
+ set(VORBIS_LIBS "-lm")
+endif()
# Find ogg dependency
find_package(Ogg REQUIRED)

View File

@ -6,6 +6,7 @@ vcpkg_from_github(
HEAD_REF master
PATCHES
0001-Dont-export-vorbisenc-functions.patch
0002-Fixup-pkgconfig-libs.patch
)
vcpkg_configure_cmake(
@ -26,8 +27,4 @@ configure_file(${SOURCE_PATH}/COPYING ${CURRENT_PACKAGES_DIR}/share/${PORT}/copy
vcpkg_copy_pdbs()
if(WIN32 AND (NOT MINGW))
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/debug/lib/pkgconfig/vorbis.pc" "-lm" "")
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/lib/pkgconfig/vorbis.pc" "-lm" "")
endif()
vcpkg_fixup_pkgconfig()

View File

@ -1,6 +1,7 @@
{
"name": "libvorbis",
"version-string": "1.3.7",
"port-version": 1,
"description": "Ogg Vorbis is a fully open, non-proprietary, patent-and-royalty-free, general-purpose compressed audio format",
"homepage": "https://github.com/xiph/vorbis",
"license": "BSD-3-Clause",