Opened 9 years ago
Last modified 5 months ago
#34094 new enhancement
ffmpeg: patch required to solve undefined type/function when using C++
Reported by: | liampg72@… | Owned by: | dbevans (David B. Evans) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.0.4 |
Keywords: | Cc: | jeremyhu (Jeremy Huddleston Sequoia), cooljeanius (Eric Gallager), chrstphrchvz (Christopher Chavez) | |
Port: | ffmpeg |
Description
Hi there,
I beleive this is a common problem when using ffmpeg in a C++ program. This link provides the detail of what needs to be patched to fix the problem.
To be clear, this is the error output I get from my program when I include "libavutil/common.h"
/opt/local/include/libavutil/common.h: In function 'int32_t av_clipl_int32_c(int64_t)': /opt/local/include/libavutil/common.h:170:47: error: 'UINT64_C' was not declared in this scope
Hope this can be solved simply. Sorry that I can't submit the patch myself, I'm not to confident with Portfiles...
Attachments (1)
Change History (8)
Changed 9 years ago by liampg72@…
Attachment: | libavutil-common.h.diff added |
---|
comment:1 Changed 9 years ago by liampg72@…
After further searching, maybe this isn't the way to fix this. Apologies. I still can't get my program to work, however...
comment:2 Changed 9 years ago by jmroot (Joshua Root)
Cc: | jeremyhu@… added; devans@… removed |
---|---|
Owner: | changed from macports-tickets@… to devans@… |
comment:4 Changed 15 months ago by jmroot (Joshua Root)
Is this still a problem with the current version?
comment:5 Changed 5 months ago by chrstphrchvz (Christopher Chavez)
The error likely no longer occurs as reported; a check that has since been added would show a different error message. See https://github.com/FFmpeg/FFmpeg/commit/66872161cb
comment:6 Changed 5 months ago by chrstphrchvz (Christopher Chavez)
Cc: | chrstphrchvz added |
---|
comment:7 Changed 5 months ago by chrstphrchvz (Christopher Chavez)
The upstream change I linked to is effectively the result of upstream's rejection of the patch the reporter attached here; they believe user C++ code is responsible for defining __STDC_CONSTANT_MACROS
. See wiki page "Including FFmpeg headers in a C++ application" and lengthy mailing list discussion regarding the patch.
Possible patch of libavutil/common.h