macros: support other names for appdata .metainfo.xml files

This commit is contained in:
Colin B. Macdonald 2018-07-01 23:23:18 -07:00
parent eb697c174d
commit e487e99ed8
2 changed files with 10 additions and 5 deletions

View File

@ -57,12 +57,14 @@ fi \
echo "function on_uninstall (desc)" > %{buildroot}%{octpkgdir}/packinfo/on_uninstall.m \
echo " error ('Can not uninstall %s installed by the redhat package manager', desc.name);" >> %{buildroot}%{octpkgdir}/packinfo/on_uninstall.m \
echo "endfunction" >> %{buildroot}%{octpkgdir}/packinfo/on_uninstall.m \
if [ -e %{_builddir}/%{buildsubdir}/build/%{octpkg}-%{version}/octave-%{octpkg}.metainfo.xml ] \
if [ -e %{_builddir}/%{buildsubdir}/build/%{octpkg}-%{version}/*.metainfo.xml ] \
then \
echo "Found octave-%{octpkg}.metainfo.xml" \
echo "Found .metainfo.xml appdata file" \
mkdir -p %{buildroot}/%{_datadir}/appdata \
cp -p %{_builddir}/%{buildsubdir}/build/%{octpkg}-%{version}/octave-%{octpkg}.metainfo.xml %{buildroot}/%{_datadir}/appdata/ \
appstream-util validate-relax --nonet %{buildroot}/%{_datadir}/appdata/octave-%{octpkg}.metainfo.xml \
cp -p %{_builddir}/%{buildsubdir}/build/%{octpkg}-%{version}/*.metainfo.xml %{buildroot}/%{_datadir}/appdata/ \
appstream-util validate-relax --nonet %{buildroot}/%{_datadir}/appdata/*.metainfo.xml \
else \
echo "Did not find a .metainfo.xml appdata file" \
fi \
%{nil}

View File

@ -21,7 +21,7 @@
Name: octave
Epoch: 6
Version: 4.2.2
Release: 5%{?rcver:.rc%{rcver}}%{?dist}
Release: 6%{?rcver:.rc%{rcver}}%{?dist}
Summary: A high-level language for numerical computations
License: GPLv3+
URL: http://www.octave.org
@ -445,6 +445,9 @@ fi
%{_pkgdocdir}/refcard*.pdf
%changelog
* Mon Jul 02 2018 Colin B. Macdonald <cbm@m.fsf.org> - 6:4.2.2-6
- macros: support other names for appdata .metainfo.xml files
* Thu Jun 28 2018 Colin B. Macdonald <cbm@m.fsf.org> - 6:4.2.2-5
- macros: support dependencies in octave_pkg_check