20-grub.install: use ~debug instead of -debug as suffix to sort correctly
For the debug BLS entries a -debug suffix was added so they are sorted after the kernel entries, but that only works with version sort and not rpm sort. So instead use ~debug prefix so rpm sort algorithm could sort it correctly. Related: rhbz#1638103 Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
This commit is contained in:
parent
67aea4f8a5
commit
efb46dff18
@ -101,8 +101,8 @@ case "$COMMAND" in
|
||||
NEWDEFAULT="${BLS_ID}"
|
||||
if [ "x$GRUB_LINUX_MAKE_DEBUG" = "xtrue" ]; then
|
||||
ARCH="$(uname -m)"
|
||||
BLS_DEBUG_ID="$(echo ${BLS_ID} | sed -e "s/\.${ARCH}/-debug.${ARCH}/")"
|
||||
BLS_DEBUG="$(echo ${BLS_TARGET} | sed -e "s/\.${ARCH}/-debug.${ARCH}/")"
|
||||
BLS_DEBUG_ID="$(echo ${BLS_ID} | sed -e "s/${KERNEL_VERSION}/${KERNEL_VERSION}~debug/")"
|
||||
BLS_DEBUG="$(echo ${BLS_TARGET} | sed -e "s/${KERNEL_VERSION}/${KERNEL_VERSION}~debug/")"
|
||||
cp -aT "${BLS_TARGET}" "${BLS_DEBUG}"
|
||||
TITLE="$(grep '^title[ \t]' "${BLS_DEBUG}" | sed -e 's/^title[ \t]*//')"
|
||||
sed -i -e "s/^title.*/title ${TITLE}${GRUB_LINUX_DEBUG_TITLE_POSTFIX}/" "${BLS_DEBUG}"
|
||||
@ -134,7 +134,7 @@ case "$COMMAND" in
|
||||
if [[ "x${GRUB_ENABLE_BLSCFG}" = "xtrue" ]] || [[ ! -f /sbin/new-kernel-pkg ]]; then
|
||||
ARCH="$(uname -m)"
|
||||
BLS_TARGET="${BLS_DIR}/${MACHINE_ID}-${KERNEL_VERSION}.conf"
|
||||
BLS_DEBUG="$(echo ${BLS_TARGET} | sed -e "s/\.${ARCH}/-debug.${ARCH}/")"
|
||||
BLS_DEBUG="$(echo ${BLS_TARGET} | sed -e "s/${KERNEL_VERSION}/${KERNEL_VERSION}~debug/")"
|
||||
rm -f "${BLS_TARGET}" "${BLS_DEBUG}"
|
||||
|
||||
for i in vmlinuz System.map config zImage.stub dtb; do
|
||||
|
Loading…
Reference in New Issue
Block a user