windows msys编译libx264,ffmpeg编译支持libx264

msys2配置参考https://blog.csdn.net/asdasfdgdhh/article/details/111518788

一: 编译x264

https://code.videolan.org/videolan/x264

pacman -S gcc mingw-w64-x86_64-toolchain yasm mingw-w64-x86_64-SDL2 make diffutils
./configure --prefix=/d/libx264 --host=x86_64-w64-mingw32 --enable-shared --extra-ldflags=-Wl,--output-def=libx264.def
make && make install

不管是mingw32还是mingw64都使用:
./configure --prefix=/usr/local/libx264 --enable-shared --host=i686-w64-mingw32 //mingw32
不用怀疑,确实叫“x86_64-w64-mingw32”不是“x86_64-w64-mingw64”。

二: ffmpeg编译支持libx264

export PKG_CONFIG_PATH=d/libx264/lib/pkgconfig:$PKG_CONFIG_PATH
./configure --prefix=/d/ffmpeg-x264 --enable-static --enable-shared --enable-gpl --enable-version3 --enable-sdl --enable-libx264 --extra-cflags=-I/d/libx264/include --extra-ldflags=-L/d/libx264/lib
make -j4 && make install
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值