Windows下使用MinGW+msys编译FFmpeg错误
来源:互联网 发布:远光软件招聘 编辑:程序博客网 时间:2024/05/22 15:49
In file included from libavformat/hlsenc.c:26:0:
c:mingwincludeunistd.h:79:1: error: expected ',' or ';' before 'int'
int __mingw_sleep( unsigned long, unsigned long );
^
In file included from libavformat/hlsenc.c:26:0:
c:mingwincludeunistd.h:105:1: error: expected ',' or ';' before 'int'
int nanosleep( const struct timespec *, struct timespec * );
^
c:mingwincludeunistd.h:125:28: error: expected ',' or ';' before 'usleep'
int _cdecl __MINGW_NOTHROW usleep( useconds_t )__MINGW_ATTRIB_DEPRECATED;
^
c:mingwincludeunistd.h:138:10: error: conflicting types for '_cdecl'
unsigned _cdecl __MINGW_NOTHROW sleep( unsigned );
^
c:mingwincludeunistd.h:125:5: note: previous declaration of '_cdecl' was here
int _cdecl __MINGW_NOTHROW usleep( useconds_t )__MINGW_ATTRIB_DEPRECATED;
^
c:mingwincludeunistd.h:138:33: error: expected ',' or ';' before 'sleep'
unsigned _cdecl __MINGW_NOTHROW sleep( unsigned );
^
c:mingwincludeunistd.h:153:12: error: expected '=', ',', ';', 'asm' or '__att
ribute__' before 'ftruncate'
int _cdecl ftruncate( int, off_t );
^
libavformat/hlsenc.c: In function 'hls_window':
libavformat/hlsenc.c:271:5: warning: format '%d' expects argument of type 'int',
but argument 3 has type 'int64_t' [-Wformat=]
avio_printf(out, "#EXT-X-MEDIA-SEQUENCE:%"PRId64"n", sequence);
^
libavformat/hlsenc.c:274:12: warning: format '%d' expects argument of type 'int'
, but argument 4 has type 'int64_t' [-Wformat=]
sequence);
^
libavformat/hlsenc.c:280:26: warning: format '%i' expects argument of type 'int'
, but argument 3 has type 'int64_t' [-Wformat=]
en->size, en->pos);
^
libavformat/hlsenc.c:280:26: warning: format '%i' expects argument of type 'int'
, but argument 4 has type 'int64_t' [-Wformat=]
c:mingwincludeunistd.h:79:1: error: expected ',' or ';' before 'int'
int __mingw_sleep( unsigned long, unsigned long );
^
In file included from libavformat/hlsenc.c:26:0:
c:mingwincludeunistd.h:105:1: error: expected ',' or ';' before 'int'
int nanosleep( const struct timespec *, struct timespec * );
^
c:mingwincludeunistd.h:125:28: error: expected ',' or ';' before 'usleep'
int _cdecl __MINGW_NOTHROW usleep( useconds_t )__MINGW_ATTRIB_DEPRECATED;
^
c:mingwincludeunistd.h:138:10: error: conflicting types for '_cdecl'
unsigned _cdecl __MINGW_NOTHROW sleep( unsigned );
^
c:mingwincludeunistd.h:125:5: note: previous declaration of '_cdecl' was here
int _cdecl __MINGW_NOTHROW usleep( useconds_t )__MINGW_ATTRIB_DEPRECATED;
^
c:mingwincludeunistd.h:138:33: error: expected ',' or ';' before 'sleep'
unsigned _cdecl __MINGW_NOTHROW sleep( unsigned );
^
c:mingwincludeunistd.h:153:12: error: expected '=', ',', ';', 'asm' or '__att
ribute__' before 'ftruncate'
int _cdecl ftruncate( int, off_t );
^
libavformat/hlsenc.c: In function 'hls_window':
libavformat/hlsenc.c:271:5: warning: format '%d' expects argument of type 'int',
but argument 3 has type 'int64_t' [-Wformat=]
avio_printf(out, "#EXT-X-MEDIA-SEQUENCE:%"PRId64"n", sequence);
^
libavformat/hlsenc.c:274:12: warning: format '%d' expects argument of type 'int'
, but argument 4 has type 'int64_t' [-Wformat=]
sequence);
^
libavformat/hlsenc.c:280:26: warning: format '%i' expects argument of type 'int'
, but argument 3 has type 'int64_t' [-Wformat=]
en->size, en->pos);
^
libavformat/hlsenc.c:280:26: warning: format '%i' expects argument of type 'int'
, but argument 4 has type 'int64_t' [-Wformat=]
make: *** [libavformat/hlsenc.o] Error 1
编译以下文件:
libavutilfile.c
libavutilfile_open.c
libavutillog.c
libavutilrandom_seed.c
libavutiltime.c
libavformatcache.c
libavformatdashenc.c
libavformatfile.c
libavformathdsenc.c
libavformatsmoothstreamingenc.c
libavformathlsenc.c
libavcodeclibxvid.c
libavcodeclibxvid_rc.c
ffmpeg.c
都有这个错误。其实是没有找到 _EXTERN_C _cdecl __MINGW_NOTHROW ,其在 window.h 中。
解决办法:在以上文件中, #include <unistd.h> 之前加上 #include <windows.h>
0 0
- Windows下使用MinGW+msys编译FFmpeg错误
- Windows下使用MinGW+msys编译FFmpeg错误
- windows下使用MinGW+msys编译ffmpeg
- windows下使用MinGW+msys编译ffmpeg
- windows下使用MinGW+msys编译ffmpeg
- windows下使用MinGW+msys编译ffmpeg
- windows下使用MinGW+msys编译ffmpeg
- windows下使用MinGW+msys编译ffmpeg
- windows下使用MinGW+msys编译ffmpeg
- windows下使用MinGW+msys编译ffmpeg
- windows下使用MinGW+msys编译ffmpeg
- windows下使用MinGW+msys编译ffmpeg
- windows 下使用 MinGW + msys 编译 ffmpeg
- windows 下使用 MinGW + msys 编译 ffmpeg
- windows下使用MinGW+msys编译ffmpeg
- windows下使用MinGW+msys编译ffmpeg
- windows下使用MinGW+msys编译ffmpeg
- windows下使用MinGW+msys编译ffmpeg
- Unique Paths and Unique Paths II
- Android ViewPager+Fragment超高仿微信主界面(带底部图标切换动画)
- 后缀自动机 例题
- python匿名函数lambda
- 认识枚举
- Windows下使用MinGW+msys编译FFmpeg错误
- 【Java TCP/IP Socket】构建和解析自定义协议消息(含代码)
- ios 微博第三方登录及得到相关参数
- jquery.desktop.js 代码分析
- webview不能正常调用Javascript代码
- mongo 过滤 分组查询
- 经常使用的web安全测试工具
- 场景一:synchronized包裹代码块
- switch ....case