当前位置: 首页 > 科技观察

如何在CentOS8-RHEL8上安装FFmpeg

时间:2023-03-21 22:16:40 科技观察

MPEG1音视频、MPEG4、h263、ac3、asf、avi、real、mjpeg、Flash等格式的多媒体文件。FFmpeg是一个跨平台应用程序,可以在各种构建环境、配置和机器架构下运行在Linux、macOS、Windows、BSD、Solaris等平台上。大多数适用于Linux的媒体播放器和音频/视频下载器和转换器(例如youtube-dl)都需要FFmpeg才能工作。如何在CentOS/RHEL8上安装FFmpeg按照以下步骤在CentOS8/RHEL8Linux发行版上安装FFmpeg。第1步:安装RPMfusionYum存储库创建RPMFusion存储库是为了提供Fedora和基于RedHat的发行版不提供的软件。此存储库中可用的所有软件应用程序均作为预编译的RPM文件提供。我们将从RPMfusion存储库在CentOS8/RHEL8上安装FFmpeg。在为EL启用RPMFusion之前,需要在RHEL或CentOS等兼容发行版上启用EPEL。[linuxidc@localhost~/www.linuxidc.com]$sudodnf-yinstallhttps://download.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm使用以下命令将其添加到您的系统中间。[linuxidc@localhost~/www.linuxidc.com]$sudodnflocalinstall--nogpgcheckhttps://download1.rpmfusion.org/free/el/rpmfusion-free-release-8.noarch.rpm[linuxidc@localhost~/www.linuxidc.com]$sudodnfinstall--nogpgcheckhttps://download1.rpmfusion.org/nonfree/el/rpmfusion-nonfee-release-8.noarch.rpm接受安装。第二步:在CentOS8/RHEL8上安装FFmpeg添加EPEL和RPMFusion仓库后,在Terminal中运行以下命令在CentOS8/RHEL8Linux系统上安装FFmpeg。[linuxidc@localhost~/www.linuxidc.com]$sudodnfinstallhttp://rpmfind.net/linux/epel/7/x86_64/Packages/s/SDL2-2.0.10-1.l7.x86_64.rpm[linuxidc@localhost~/www.linuxidc.com]$sudodnfinstallffmpeg通过运行以下命令安装开发库:[linuxidc@localhost~/www.linuxidc.com]$sudodnf-yinstallffmpeg-devel第3步:使用以下命令检查CentOS/RHEL8上的FFmpeg版本命令检查安装在RHEL/CentOS系统上的FFmpeg的版本。[linuxidc@localhost~/www.linuxidc.com]$rpm-qiffmpeg[linuxidc@localhost~/www.linuxidc.com]$ffmpeg-versionffmpegversion4.2.2版权所有(c)2000-2019theFFmpegdevelopersbuiltwithgcc8(GCC)FFmpeghelp[linuxidc@localhost~/www.linuxidc.com]$ffmpeg--helpOK。就这样吧。