【问题标题】:RPM build correctly setting Provides on openSUSE, but not FedoraRPM 构建正确设置 在 openSUSE 上提供,但在 Fedora 上不提供
【发布时间】:2016-07-07 19:43:02
【问题描述】:

我有一个 MakeMKV 的 RPM 规范文件,它被上传到 OBS 以构建 Fedora 和 openSUSE 的软件包。两个发行版的 specfile 相同,但只有 openSUSE 正确地将构建的库添加到构建包的提供部分,导致包安装在 Fedora 上失败。

我尝试将所有文​​件放在一个包中,但这仍然不允许在 Fedora 上安装。 openSUSE 会检测这些库是否都放在同一个包中或单独打包。

这是我的规范文件:

Name: makemkv
Version: 1.9.10
Release: 0
Summary: DVD and Blu-ray to MKV converter and network streamer
License: SUSE-NonFree
Group: Productivity/Multimedia/Other
Url: http://www.makemkv.com
Source0: %name-oss-%version.tar.gz
Source1: %name-bin-%version.tar.gz
BuildRequires: pkgconfig(zlib) pkgconfig(openssl) pkgconfig(expat) pkgconfig(libavcodec) pkgconfig(libavutil)
%if 0%{?centos} || 0%{?fedora} || 0%{?rhel} || 0%{?scientificlinux}
BuildRequires: pkgconfig
%endif
%if 0%{?centos} || 0%{?rhel} || 0%{?scientificlinux}
BuildRequires: libqt4-devel
%endif
%if 0%{?fedora}
BuildRequires: qt5-qtbase-devel
%endif
%if 0%{?suse_version}
BuildRequires: pkg-config libqt5-qtbase-devel update-desktop-files
%endif

%description
MakeMKV is your one-click solution to convert video that you own into free and patents-unencumbered format that can be played everywhere. MakeMKV is a format converter, otherwise called "transcoder". It converts the video clips from proprietary (and usually encrypted) disc into a set of MKV files, preserving most information but not changing it in any way. The MKV format can store multiple video/audio tracks with all meta-information and preserve chapters. There are many players that can play MKV files nearly on all platforms, and there are tools to convert MKV files to many formats, including DVD and Blu-ray discs.

Additionally MakeMKV can instantly stream decrypted video without intermediate conversion to wide range of players, so you may watch Blu-ray and DVD discs with your favorite player on your favorite OS or on your favorite device.

%package -n libdriveio0
Summary: DVD and Blu-ray to MKV converter and network streamer

%description -n libdriveio0
MakeMKV is your one-click solution to convert video that you own into free and patents-unencumbered format that can be played everywhere. MakeMKV is a format converter, otherwise called "transcoder". It converts the video clips from proprietary (and usually encrypted) disc into a set of MKV files, preserving most information but not changing it in any way. The MKV format can store multiple video/audio tracks with all meta-information and preserve chapters. There are many players that can play MKV files nearly on all platforms, and there are tools to convert MKV files to many formats, including DVD and Blu-ray discs.

Additionally MakeMKV can instantly stream decrypted video without intermediate conversion to wide range of players, so you may watch Blu-ray and DVD discs with your favorite player on your favorite OS or on your favorite device.

%package -n libmakemkv1
Summary: DVD and Blu-ray to MKV converter and network streamer

%description -n libmakemkv1
MakeMKV is your one-click solution to convert video that you own into free and patents-unencumbered format that can be played everywhere. MakeMKV is a format converter, otherwise called "transcoder". It converts the video clips from proprietary (and usually encrypted) disc into a set of MKV files, preserving most information but not changing it in any way. The MKV format can store multiple video/audio tracks with all meta-information and preserve chapters. There are many players that can play MKV files nearly on all platforms, and there are tools to convert MKV files to many formats, including DVD and Blu-ray discs.

Additionally MakeMKV can instantly stream decrypted video without intermediate conversion to wide range of players, so you may watch Blu-ray and DVD discs with your favorite player on your favorite OS or on your favorite device.

%package -n libmmbd0
Summary: DVD and Blu-ray to MKV converter and network streamer

%description -n libmmbd0
MakeMKV is your one-click solution to convert video that you own into free and patents-unencumbered format that can be played everywhere. MakeMKV is a format converter, otherwise called "transcoder". It converts the video clips from proprietary (and usually encrypted) disc into a set of MKV files, preserving most information but not changing it in any way. The MKV format can store multiple video/audio tracks with all meta-information and preserve chapters. There are many players that can play MKV files nearly on all platforms, and there are tools to convert MKV files to many formats, including DVD and Blu-ray discs.

Additionally MakeMKV can instantly stream decrypted video without intermediate conversion to wide range of players, so you may watch Blu-ray and DVD discs with your favorite player on your favorite OS or on your favorite device.

%prep
tar xf %{SOURCE0}
tar xf %{SOURCE1}

%build
cd %{name}-oss-%{version}
%configure
make %{?_smp_mflags}

%install
cd %{name}-oss-%{version}
make install DESTDIR=%buildroot
%if 0%{?suse_version}
%suse_update_desktop_file -r makemkv
%suse_update_desktop_file -c makemkv MakeMKV "DVD and Blu-ray to MKV converter and network streamer" makemkv makemkv AudioVideo AudioVideoEditing
%endif

cd ../%{name}-bin-%{version}
mkdir tmp
echo accepted > tmp/eula_accepted
make install DESTDIR=%buildroot

%if "/usr/lib" != "%_libdir"
mv %buildroot/usr/lib/ %buildroot/%_libdir
%endif

%post -n libdriveio0 -p /sbin/ldconfig
%postun -n libdriveio0 -p /sbin/ldconfig
%post -n libmakemkv1 -p /sbin/ldconfig
%postun -n libmakemkv1 -p /sbin/ldconfig
%post -n libmmbd0 -p /sbin/ldconfig
%postun -n libmmbd0 -p /sbin/ldconfig

%files
%defattr(-,root,root)
#oss
%dir /usr/share/icons/hicolor
%dir /usr/share/icons/hicolor/*
%dir /usr/share/icons/hicolor/*/apps
/%_bindir/makemkv
/usr/share/applications/makemkv.desktop
/usr/share/icons/hicolor/*/apps/makemkv.png
#bin
/%_bindir/makemkvcon
/%_bindir/mmdtsdec
/usr/share/MakeMKV/

%files -n libdriveio0
%defattr(-,root,root)
/%_libdir/libdriveio.so.0

%files -n libmakemkv1
%defattr(-,root,root)
/%_libdir/libmakemkv.so.1

%files -n libmmbd0
%defattr(-,root,root)
/%_libdir/libmmbd.so.0

【问题讨论】:

    标签: rpm-spec


    【解决方案1】:

    库的权限设置不正确。跑步

    chmod 755 %buildroot/%_libdir/lib*.so*
    

    修复了这个问题,然后 Fedora 正确设置了提供字段。

    【讨论】:

      猜你喜欢
      • 2015-05-21
      • 2023-04-06
      • 2017-01-14
      • 1970-01-01
      • 2019-09-20
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-10-21
      相关资源
      最近更新 更多