diff --git a/sys-apps/memtest86+/files/39_memtest86+ b/sys-apps/memtest86+/files/39_memtest86+ index 14f27a2768889..10e1964cb8dfa 100644 --- a/sys-apps/memtest86+/files/39_memtest86+ +++ b/sys-apps/memtest86+/files/39_memtest86+ @@ -4,30 +4,67 @@ memtest=/boot/memtest86plus/memtest -if [ -f "${memtest}" ]; then - device="$("${grub_probe}" --target=device "${memtest}")" - path="$(make_system_path_relative_to_its_root "${memtest}")" +memtestbsd=/boot/memtest86plus/memtest.netbsd + +if [ -f "${memtest}" ] && [ -f "${memtestbsd}" ]; then + multiple_memtest=true +fi + +submenu_indentation="" +if [ "x${multiple_memtest}" = xtrue ] && [ "x${GRUB_DISABLE_SUBMENU}" != xy ]; then + submenu_indentation="${grub_tab}" cat <&2 + device="$("${grub_probe}" --target=device "${memtest}")" path="$(make_system_path_relative_to_its_root "${memtest}")" cat <&2 + + device="$("${grub_probe}" --target=device "${memtestbsd}")" + path="$(make_system_path_relative_to_its_root "${memtestbsd}")" + cat <