76 |
{ |
{ |
77 |
local splashimage |
local splashimage |
78 |
local grub_disk |
local grub_disk |
79 |
|
local grub_prefix |
80 |
|
|
81 |
if [[ -z ${PARTITION_DISK_BOOT} ]] |
if [[ -z ${PARTITION_DISK_BOOT} ]] |
82 |
then |
then |
83 |
grub_disk="${PARTITION_DISK_ROOT}" |
grub_disk="${PARTITION_DISK_ROOT}" |
84 |
|
# if no extra partition for grub was defined, we need the bootprefix set to /boot |
85 |
|
grub_prefix="/boot" |
86 |
else |
else |
87 |
grub_disk="${PARTITION_DISK_BOOT}" |
grub_disk="${PARTITION_DISK_BOOT}" |
88 |
|
# got a extra boot partition, no bootprefix needed |
89 |
|
grub_prefix="" |
90 |
fi |
fi |
91 |
|
|
92 |
# create an empty one |
# create an empty one |
105 |
if [[ -f ${INSTALL_ROOT}/boot/${splashimage} ]] |
if [[ -f ${INSTALL_ROOT}/boot/${splashimage} ]] |
106 |
then |
then |
107 |
add_grub_conf "# splash image" |
add_grub_conf "# splash image" |
108 |
add_grub_conf "splashimage $(convert_device ${grub_disk})/boot/${splashimage}" |
add_grub_conf "splashimage $(convert_device ${grub_disk})${grub_prefix}/${splashimage}" |
109 |
add_grub_conf "foreground FFFFFF" |
add_grub_conf "foreground FFFFFF" |
110 |
add_grub_conf "background 253861" |
add_grub_conf "background 253861" |
111 |
|
|
118 |
|
|
119 |
add_grub_conf "title Magellan-Linux $(< ${INSTALL_ROOT}/etc/mageversion) ($(readlink ${INSTALL_ROOT}/boot/vmlinuz | sed s:kernel-::))" |
add_grub_conf "title Magellan-Linux $(< ${INSTALL_ROOT}/etc/mageversion) ($(readlink ${INSTALL_ROOT}/boot/vmlinuz | sed s:kernel-::))" |
120 |
add_grub_conf "root $(convert_device ${grub_disk})" |
add_grub_conf "root $(convert_device ${grub_disk})" |
121 |
add_grub_conf "kernel /boot/$(readlink ${INSTALL_ROOT}/boot/vmlinuz) root=UUID=$(get_uuid ${PARTITION_DISK_ROOT})" |
add_grub_conf "kernel ${grub_prefix}/$(readlink ${INSTALL_ROOT}/boot/vmlinuz) root=UUID=$(get_uuid ${PARTITION_DISK_ROOT})" |
122 |
add_grub_conf "initrd /boot/$(readlink ${INSTALL_ROOT}/boot/initrd)" |
add_grub_conf "initrd ${grub_prefix}/$(readlink ${INSTALL_ROOT}/boot/initrd)" |
123 |
|
|
124 |
# add an empty line as spacer between other boot entries |
# add an empty line as spacer between other boot entries |
125 |
add_grub_conf "" |
add_grub_conf "" |