Skip to content

[ffmpeg] Fix FindFFMPEG lib versions for building opencv[ffmpeg]#16882

Merged
vicroms merged 6 commits intomicrosoft:masterfrom
genevanmeter:master
Mar 31, 2021
Merged

[ffmpeg] Fix FindFFMPEG lib versions for building opencv[ffmpeg]#16882
vicroms merged 6 commits intomicrosoft:masterfrom
genevanmeter:master

Conversation

@genevanmeter
Copy link
Contributor

libavutil, libavdevice, etc. define their versions separate from FFMPEG main version in a version.h file located with each component headers.
This change fixes building opencv[ffmpeg] when it attempts to discover the individual versions of FFMPEG libs. Before this change opencv[ffmpeg] would build but the FFMPEG functionality was disabled since all the lib versions were set to 4.3.1 and didn't meet its requirements.

libavutil, libavdevice, etc. define their versions separate from FFMPEG main version in a version.h file located with each component headers.
This change fixes building opencv[ffmpeg] when it attempts to discover the individual versions of FFMPEG libs. Before this change opencv[ffmpeg] would build but the FFMPEG functionality was disabled since all the lib versions were set to 4.3.1
@ghost
Copy link

ghost commented Mar 25, 2021

CLA assistant check
All CLA requirements met.

Copy link
Contributor

@Cheney-W Cheney-W left a comment

Choose a reason for hiding this comment

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

  1. Please modify the Port-Version of CONTROL to 13.
  2. Please run .\vcpkg.exe x-add-version ffmpeg to update the json file.

@Cheney-W Cheney-W self-assigned this Mar 26, 2021
@Cheney-W Cheney-W added category:port-bug The issue is with a library, which is something the port should already support requires:author-response labels Mar 26, 2021
Ran vcpkg.exe x-add-version ffmpeg
@Cheney-W
Copy link
Contributor

Cheney-W commented Mar 26, 2021

About port's json file, each of your commit changes will modify its git tree value, which means you need to update json file after you have done all the changes and executed the git commit -m "XXX" command. The specific sequence is as follows:

Git checkout -b "xxx"
Modify the local files
Git diff
Git add .
Git commit -m "comments description"
.\vcpkg x-add-version {Port name}
Git add .
Git commit -m "comments description"
git push

If you haven't executed the . \vcpkg x-add-version {port name} on the current branch, you need to use it after your modification is completed and submitted.
If you have executed this command on the current branch, you need to execute the following command when you need to update the json file:
.\vcpkg.exe x-add-version {port name} --overwrite-version
So, for this PR, you need to execute .\vcpkg.exe x-add-version {port name} --overwrite-version again.

BTW, osgearth:x64-linux failure is not related with your PR, this is a CI issue, it will be fixed by PR: #16904.

@JackBoosY JackBoosY added the depends:different-pr This PR or Issue depends on a PR which has been filed label Mar 26, 2021
@mcmtroffaes
Copy link
Contributor

This is great in principle, however I'm not in favour of hardcoding these versions. May I suggest instead to extract the versions from the source files (e.g. from the version.h file of each library, such as https://github.com/FFmpeg/FFmpeg/blob/master/libavcodec/version.h)?

@Cheney-W Cheney-W removed depends:different-pr This PR or Issue depends on a PR which has been filed requires:author-response labels Mar 29, 2021
@JackBoosY
Copy link
Contributor

Please solve the file conflicts first.

Thanks.

@JackBoosY JackBoosY added info:needs-maintainer-attention Lets the current 'on rotation' vcpkg maintainer know they need to look at this. and removed requires:author-response labels Mar 31, 2021
@genevanmeter
Copy link
Contributor Author

I believe this fixes #16741 #13859

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

category:port-bug The issue is with a library, which is something the port should already support info:needs-maintainer-attention Lets the current 'on rotation' vcpkg maintainer know they need to look at this.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants