Windows下使用MinGW+msys编译FFmpeg错误
来源:互联网 发布:专业的vb振动电机 编辑:程序博客网 时间:2024/05/01 19:37
In file included from libavformat/hlsenc.c:26:0:
c:\mingw\include\unistd.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:\mingw\include\unistd.h:105:1: error: expected ',' or ';' before 'int'
int nanosleep( const struct timespec *, struct timespec * );
^
c:\mingw\include\unistd.h:125:28: error: expected ',' or ';' before 'usleep'
int _cdecl __MINGW_NOTHROW usleep( useconds_t )__MINGW_ATTRIB_DEPRECATED;
^
c:\mingw\include\unistd.h:138:10: error: conflicting types for '_cdecl'
unsigned _cdecl __MINGW_NOTHROW sleep( unsigned );
^
c:\mingw\include\unistd.h:125:5: note: previous declaration of '_cdecl' was here
int _cdecl __MINGW_NOTHROW usleep( useconds_t )__MINGW_ATTRIB_DEPRECATED;
^
c:\mingw\include\unistd.h:138:33: error: expected ',' or ';' before 'sleep'
unsigned _cdecl __MINGW_NOTHROW sleep( unsigned );
^
c:\mingw\include\unistd.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:\mingw\include\unistd.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:\mingw\include\unistd.h:105:1: error: expected ',' or ';' before 'int'
int nanosleep( const struct timespec *, struct timespec * );
^
c:\mingw\include\unistd.h:125:28: error: expected ',' or ';' before 'usleep'
int _cdecl __MINGW_NOTHROW usleep( useconds_t )__MINGW_ATTRIB_DEPRECATED;
^
c:\mingw\include\unistd.h:138:10: error: conflicting types for '_cdecl'
unsigned _cdecl __MINGW_NOTHROW sleep( unsigned );
^
c:\mingw\include\unistd.h:125:5: note: previous declaration of '_cdecl' was here
int _cdecl __MINGW_NOTHROW usleep( useconds_t )__MINGW_ATTRIB_DEPRECATED;
^
c:\mingw\include\unistd.h:138:33: error: expected ',' or ';' before 'sleep'
unsigned _cdecl __MINGW_NOTHROW sleep( unsigned );
^
c:\mingw\include\unistd.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
编译以下文件:
libavutil\file.c
libavutil\file_open.c
libavutil\log.c
libavutil\random_seed.c
libavutil\time.c
libavformat\cache.c
libavformat\dashenc.c
libavformat\file.c
libavformat\hdsenc.c
libavformat\smoothstreamingenc.c
libavformat\hlsenc.c
libavcodec\libxvid.c
libavcodec\libxvid_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
- 仿微信/支付宝的密码输入框效果 android
- 文件的上传,下载,预览
- MFC ListControl用法
- windows远程桌面用户已达上限
- printk调用过程
- Windows下使用MinGW+msys编译FFmpeg错误
- CGFloat,CGPoint,CGSize,CGRect
- P124 第46题 Fibonacci
- TestNG监听器实现用例运行失败自动截图、重运行功能
- Find Exchange Servers in the Local Active Directory Site using PowerShell
- android官网没法访问issue
- QT4 编译错误 error: collect2: ld returned 1 exit status
- 软件工程到底学什么
- 循环链表和约瑟夫环