Fix build error when custom vendor

This commit is contained in:
xiaochuannan 2024-11-11 10:45:14 +08:00
parent 9f6685dd0d
commit e08938c88b

View File

@ -10,7 +10,7 @@
Name: supermin
Version: 5.1.19
Release: 19
Release: 20
Summary: A tool for building supermin appliances, required by libguestfs
License: GPLv2+
URL: http://libguestfs.org/
@ -64,7 +64,7 @@ This contains man files for the using of supermin.
%prep
%autosetup -p1
%if %{!?openEuler:1}0
%if "%{vendor}" != "openEuler"
sed -i 's/; "openEuler"/&; "%{vendor}"/' ./src/ph_rpm.ml
num=$(grep -n "etc/openEuler-release" ./src/ph_rpm.ml |awk -F ":" '{printf $1}')
sed -i "N;$num i\ (stat \"/etc/%{vendor}-release\").st_kind = S_REG ||" ./src/ph_rpm.ml
@ -97,6 +97,9 @@ install -m 0755 %{SOURCE2} $RPM_BUILD_ROOT%{_rpmconfigdir}/
%{_mandir}/man1/*
%changelog
* Mon Nov 11 2024 xiaochn <xiaochuannan@inspur.com> - 5.1.19-20
- Fix build error when custom vendor(The openEuler macro is used not only for openEuler, but also for downstream distributions)
* Thu Nov 30 2023 chendexi <chendexi@kylinos.cn> - 5.1.19-19
- Modify release file name due to release package name change