centos 安装 ffmpeg

使用yum方式安装ffmpeg:

先安装Nux Dextop仓库:

Nux Dextop库依赖于EPEL库,所有要先安装EPEL库(需要管理员权限)。 如果安装过则跳过。

$ su root
$ yum -y install epel-release

对于RHEL/CentOS 7(复制/粘贴): 

$ rpm -Uvh http://li.nux.ro/download/nux/dextop/el7/x86_64/nux-dextop-release-0-5.el7.nux.noarch.rpm

检查Nux Dextop是否安装成功: 

$ yum repolist

如果仓库列表中有Nux Dextop就安装成功。 

安装FFmpeg 和 FFmpeg开发包 

sudo yum install ffmpeg ffmpeg-devel -y

参考:

https://www.jianshu.com/p/86d16189832e

https://www.cnblogs.com/wpjamer/p/ffmpeg.html

关闭防火墙:

systemctl stop firewalld.service #停止firewall
systemctl disable firewalld.service #禁止firewall开机启动
firewall-cmd --state #查看默认防火墙状态(关闭后显示notrunning,开启后显示running)

源代码编译方式安装:

原文链接:https://www.cnblogs.com/cheng5x/p/5646920.html

安装的时候如果权限不够出错了,用root帐号登陆安装就没问题了。

原文地址:https://www.cnblogs.com/gavinyyb/p/8341953.html