From: Stephan Wiesand Date: Mon, 26 Mar 2018 18:21:19 +0000 (+0200) Subject: redhat: Create unique debuginfo packages for kmods X-Git-Tag: upstream/1.8.1_pre2^2~82 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=a819cf483e03d32b2213175e19e628d7c3d8194d;p=packages%2Fo%2Fopenafs.git redhat: Create unique debuginfo packages for kmods Commit 443dd5367e0cd9050ad39a6594c5be521271b4e9 ("redhat: separate debuginfo package for kmod rpm") introduced the creation of separate debuginfo packages for the kmod packages. As such, this is useful, but all debuginfo packages for a given OpenAFS release ended up with the same name/version/release for the kmod debuginfo package, no matter which kernel release or variant the kmod was built for. Move the additional black magic from the spec into the kmodtool script where we have the means to do better: Use the same naming and versioning conventions as for the kmod-openafs packages themselves. Reviewed-on: https://gerrit.openafs.org/12977 Tested-by: BuildBot Reviewed-by: Andrew Deason Reviewed-by: Michael Meffie Tested-by: Michael Meffie Reviewed-by: Benjamin Kaduk (cherry picked from commit 387ae9536888419d7b101513e04e1c644e3218d6) Change-Id: I220408eacd0c39449843240f225cfced163cbff7 Reviewed-on: https://gerrit.openafs.org/12986 Tested-by: BuildBot Reviewed-by: Michael Meffie Reviewed-by: Stephan Wiesand Reviewed-by: Benjamin Kaduk --- diff --git a/src/packaging/RedHat/openafs-kmodtool b/src/packaging/RedHat/openafs-kmodtool index b6dee3287..6721b792f 100644 --- a/src/packaging/RedHat/openafs-kmodtool +++ b/src/packaging/RedHat/openafs-kmodtool @@ -92,6 +92,9 @@ get_rpmtemplate () esac cat < /dev/null || : %postun -n kmod-${kmod_name}${dashvariant} @@ -115,6 +128,9 @@ ${depmod} -aF /boot/System.map-${kname} ${kname} &> /dev/null || : %defattr(644,root,root,755) /lib/modules/${kname}/extra/${kmod_name}/ +%files -f kmod-debuginfo.list -n kmod-%{kmod_name}${dashvariant}-debuginfo +%defattr(-,root,root) + EOF } diff --git a/src/packaging/RedHat/openafs.spec.in b/src/packaging/RedHat/openafs.spec.in index 410ddc74e..9a039a41f 100644 --- a/src/packaging/RedHat/openafs.spec.in +++ b/src/packaging/RedHat/openafs.spec.in @@ -403,17 +403,6 @@ krb4 lookalike services. ############################################################################## %if %{build_modules} -# Make debuginfo for the kernel components into their own package -# so we can upgrade kernel and userspace seperately and still debug each -%package -n %{name}-kernel-debuginfo -Summary: Debug information for %{name} kernel modules -Group: Development/Debug -AutoReqProv: no -%description -n %{name}-kernel-debuginfo -This package provides debug information for %{name} kernel modules. - -%{expand:%%global _find_debuginfo_opts %{?_find_debuginfo_opts} -p '.*openafs.ko(\.debug)?' -o kmod-debuginfo.list} - %{expand:%(%{kmodtool} rpmtemplate %{kmod_name} %{kverrel} %{depmod} %{kvariants} 2>/dev/null)} %endif @@ -1465,11 +1454,6 @@ dkms remove -m %{name} -v %{dkms_version} --rpm_safe_upgrade --all ||: %endif %endif # build_userspace -%if %{build_modules} -%files -f kmod-debuginfo.list -n %{name}-kernel-debuginfo -%defattr(-,root,root) -%endif - ############################################################################## ### ### openafs.spec change log