![AlmaLinux 无法安装 ffmpeg](https://linux22.com/image/785471/AlmaLinux%20%E6%97%A0%E6%B3%95%E5%AE%89%E8%A3%85%20ffmpeg.png)
新安装 AlmaLinux 8 (r8.7 (Stone Smilodon))。我在准备安装 ffmpeg 时运行了以下命令:
sudo dnf -y install https://download.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
sudo yum install yum-utils -y
sudo yum-config-manager --enable powertools
sudo dnf install --nogpgcheck https://mirrors.rpmfusion.org/free/el/rpmfusion-free-release-8.noarch.rpm -y
sudo dnf install --nogpgcheck https://mirrors.rpmfusion.org/nonfree/el/rpmfusion-nonfree-release-8.noarch.rpm -y
当我运行 final 时sudo dnf install ffmpeg ffmpeg-devel
,出现以下错误:
Last metadata expiration check: 0:22:38 ago on Tue 25 Apr 2023 11:48:30 AM MDT.
No match for argument: ffmpeg
Error: Unable to find a match: ffmpeg
我在之前的机器和其他版本的 'Nix 上安装并运行过 ffmpeg,没有任何问题,但这个问题让我很困惑。我运行了dnf repolist
,得到了这个:
repo id repo name
appstream AlmaLinux 8 - AppStream
baseos AlmaLinux 8 - BaseOS
dell-omsa-indep Dell OMSA repository - Hardware independent
dell-omsa-specific Dell OMSA repository - Hardware specific
dell-system-update_dependent dell-system-update_dependent
dell-system-update_independent dell-system-update_independent
elevate ELevate
epel Extra Packages for Enterprise Linux 8 - x86_64
extras AlmaLinux 8 - Extras
influxdata InfluxData Repository - Stable
influxdb InfluxDB Repository
powertools AlmaLinux 8 - PowerTools
因此存储库是存在且正确的。
我不知道还要检查哪里。这应该很简单。有人能帮我安装吗?
答案1
以下步骤对我有用:
dnf config-manager --set-enabled powertools
dnf install --nogpgcheck https://mirrors.rpmfusion.org/free/el/rpmfusion-free-release-$(rpm -E %rhel).noarch.rpm -y
dnf install --nogpgcheck https://mirrors.rpmfusion.org/nonfree/el/rpmfusion-nonfree-release-$(rpm -E %rhel).noarch.rpm -y
dnf install ffmpeg
你甚至不需要 epel。对于 ffmpeg 来说,powertools 和 rpmfusion repos 就足够了。