Discussion:
[PATCH] rpm/kernel-obs-build.spec.in: use get_kernel_version
(too old to reply)
Andreas Schwab
2014-09-01 09:01:23 UTC
Permalink
Raw Message
---
rpm/kernel-obs-build.spec.in | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/rpm/kernel-obs-build.spec.in b/rpm/kernel-obs-build.spec.in
index ac42e13..42febe6 100644
--- a/rpm/kernel-obs-build.spec.in
+++ b/rpm/kernel-obs-build.spec.in
@@ -116,9 +116,9 @@ ROOT=""
-k /boot/vmlinuz-xen -M /boot/System.map-*-xen -i /tmp/initrd.xen
%endif
%else
-dracut --host-only --drivers="$KERNEL_MODULES" --force /tmp/initrd.kvm `echo /boot/%{kernel_name}-*-default | sed -n -e 's,[^-]*-\(.*-default\),\1,p'`
+dracut --host-only --drivers="$KERNEL_MODULES" --force /tmp/initrd.kvm `get_kernel_version /boot/%{kernel_name}-*-default`
%ifarch %ix86 x86_64
-dracut --host-only --drivers="$KERNEL_MODULES xenblk" --force /tmp/initrd.xen `echo /boot/%{kernel_name}-*-xen | sed -n -e 's,[^-]*-\(.*-xen\),\1,p'`
+dracut --host-only --drivers="$KERNEL_MODULES xenblk" --force /tmp/initrd.xen `get_kernel_version /boot/%{kernel_name}-*-xen`
%endif
%endif
--
2.1.0
--
Andreas Schwab, SUSE Labs, schwab-***@public.gmane.org
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."
Loading...