Skip to content

Commit

Permalink
[ffmpeg] Fix failure of cross-compiling for ffmpeg due to use inappro…
Browse files Browse the repository at this point in the history
…priate strip. (#25596)

* Fix failure of cross-compiling for ffmpeg due to use inappropriate strip.

* Update port version of ffmpeg.

* Remove redundant adjust condition.

* Update version database

Co-authored-by: Jamlys Lee <jamlys_lee@163.com>
  • Loading branch information
Jamlys and Jamlys Lee committed Jul 7, 2022
1 parent 4f0bb16 commit 526f862
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 2 deletions.
7 changes: 7 additions & 0 deletions ports/ffmpeg/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@ if(VCPKG_TARGET_IS_MINGW)
elseif(VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
string(APPEND OPTIONS " --target-os=mingw64")
endif()
elseif(VCPKG_TARGET_IS_LINUX)
string(APPEND OPTIONS " --target-os=linux")
elseif(VCPKG_TARGET_IS_WINDOWS)
string(APPEND OPTIONS " --target-os=win32")
elseif(VCPKG_TARGET_IS_OSX)
Expand Down Expand Up @@ -458,6 +460,11 @@ endif()

set(OPTIONS_CROSS " --enable-cross-compile")

# ffmpeg needs --cross-prefix option to use appropriate tools for cross-compiling.
if(VCPKG_DETECTED_CMAKE_C_COMPILER MATCHES "(/.+)gcc$")
string(APPEND OPTIONS_CROSS " --cross-prefix=${CMAKE_MATCH_1}")
endif()

if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
string(APPEND OPTIONS_CROSS " --arch=x86_64")
else()
Expand Down
2 changes: 1 addition & 1 deletion ports/ffmpeg/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "ffmpeg",
"version": "4.4.1",
"port-version": 13,
"port-version": 14,
"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."
Expand Down
2 changes: 1 addition & 1 deletion versions/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -2234,7 +2234,7 @@
},
"ffmpeg": {
"baseline": "4.4.1",
"port-version": 13
"port-version": 14
},
"ffnvcodec": {
"baseline": "11.1.5.0",
Expand Down
5 changes: 5 additions & 0 deletions versions/f-/ffmpeg.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "bd232549fb2bcffed0dcfac1e7e6a54f5a91b5cc",
"version": "4.4.1",
"port-version": 14
},
{
"git-tree": "ad64f5ffe64b5fcd97e2e6d98273b70d498d6af0",
"version": "4.4.1",
Expand Down

0 comments on commit 526f862

Please sign in to comment.