mirror of
https://github.com/systemd/systemd
synced 2024-10-04 15:21:01 +00:00
mkosi: Skip debuginfo workaround on newer rpm
The corresponding bug was fixed in rpm 4.20 (of which the alpha is in rawhide as rpm 4.19.91) so skip the workaround when we detect a newer rpm version.
This commit is contained in:
parent
8c335463d9
commit
3b046883ad
|
@ -20,13 +20,15 @@ else
|
|||
TS="${SOURCE_DATE_EPOCH:-$(date +%s)}"
|
||||
fi
|
||||
|
||||
# Fix the %install override so debuginfo packages are generated even when --build-in-place is used.
|
||||
# See https://github.com/rpm-software-management/rpm/issues/3042.
|
||||
tee --append /usr/lib/rpm/redhat/macros <<'EOF'
|
||||
if systemd-analyze compare-versions "$(rpm --version | cut -d ' ' -f3)" lt "4.19.91"; then
|
||||
# Fix the %install override so debuginfo packages are generated even when --build-in-place is used.
|
||||
# See https://github.com/rpm-software-management/rpm/issues/3042.
|
||||
tee --append /usr/lib/rpm/redhat/macros <<'EOF'
|
||||
%install %{?_enable_debug_packages:%{debug_package}}\
|
||||
%%install\
|
||||
%{nil}
|
||||
EOF
|
||||
fi
|
||||
|
||||
VERSION="$(cat meson.version)"
|
||||
RELEASE="$(date "+%Y%m%d%H%M%S" --date "@$TS")"
|
||||
|
|
|
@ -26,12 +26,14 @@ fi
|
|||
# extension.
|
||||
find "pkg/$ID" -name "files.*" -exec sed --in-place 's/\.gz$//' {} \;
|
||||
|
||||
# Fix the %install override so debuginfo packages are generated.
|
||||
tee --append /usr/lib/rpm/suse/macros <<'EOF'
|
||||
if systemd-analyze compare-versions "$(rpm --version | cut -d ' ' -f3)" lt "4.20"; then
|
||||
# Fix the %install override so debuginfo packages are generated.
|
||||
tee --append /usr/lib/rpm/suse/macros <<'EOF'
|
||||
%install %{debug_package}\
|
||||
%%install\
|
||||
%{nil}
|
||||
EOF
|
||||
fi
|
||||
|
||||
VERSION="$(cat meson.version)"
|
||||
RELEASE="$(date "+%Y%m%d%H%M%S" --date "@$TS")"
|
||||
|
|
Loading…
Reference in a new issue