7.12. Building a bootloader

#### Cross-Compiled Linux From Scratch - Version 1.0.0rc1-x86_64-Pure64

### Chapter 7. If You Are Going to Boot

- Prev

  Linux-2.6.17.1

- Next

  Bin86-0.16.17

- Up.
- Home

# 7.12. Building a bootloader

On x86 and x86_64 (multilib) architectures, the preferred bootloader is Grub. Unfortunately, Grub doesn"t work on x86_64 Pure64 - the stage2 files can be correctly built as 32-bit, but the grub shell is a 64-bit program, and tries to execute some of the stage2 routines - this results in a segmentation fault. Therefore, in the final system we use Lilo as the bootloader.

If you already have a bootloader, such as Grub, installed on the system then you should use that to make your new kernel bootable.

### Note

We will now cross-compile Bin86 and Lilo - these instructions assume you are using an x86_64 machine (e.g. booted fron a Live CD), either pure64 or multilib. This approach will not work if you are running the machine as i686, because a 32-bit kernel will not be able to execute a 64-bit binary to install the bootloader. If that is the case, you will need to install an i686 bootloader on the host system.

- Prev

  Linux-2.6.17.1

- Next

  Bin86-0.16.17

- Up.
- Home.