Fix build for non-EFI architectures.
Change-Id: Ic2c8a9a64e63f4b844e964eb1066291d2edda7b3 Reviewed-on: https://review.haiku-os.org/c/haiku/+/2343 Reviewed-by: Adrien Destugues <[email protected]>
This commit is contained in:
committed by
waddlesplash
parent
228006ea74
commit
768f6b3bc4
@@ -41,16 +41,25 @@ BuildMBR $(baseMBR) : $(mbrSource) ;
|
|||||||
MakeLocate $(baseMBR) : $(HAIKU_OUTPUT_DIR) ;
|
MakeLocate $(baseMBR) : $(HAIKU_OUTPUT_DIR) ;
|
||||||
MakeLocate $(HAIKU_ANYBOOT) : $(HAIKU_ANYBOOT_DIR) ;
|
MakeLocate $(HAIKU_ANYBOOT) : $(HAIKU_ANYBOOT_DIR) ;
|
||||||
|
|
||||||
if $(HAIKU_ANYBOOT_LEGACY) = 1 {
|
# Currently the Anyboot image is available only for EFI+BIOS or BIOS-only
|
||||||
BuildAnybootImage $(HAIKU_ANYBOOT) : $(baseMBR) : $(HAIKU_CD_BOOT_IMAGE)
|
# systems. It is not needed for other systems, where usually you can boot
|
||||||
: $(HAIKU_IMAGE_NAME) ;
|
# the same way from an USB or CD drive, instead of needing completely
|
||||||
} else {
|
# different layouts.
|
||||||
local efiLoader = haiku_loader.efi ;
|
for platform in [ MultiBootSubDirSetup ] {
|
||||||
local efiPartition = esp.image ;
|
on $(platform) {
|
||||||
MakeLocate $(efiPartition) ;
|
if $(TARGET_BOOT_PLATFORM) = efi {
|
||||||
BuildEfiSystemPartition $(efiPartition) : $(efiLoader) ;
|
local efiLoader = haiku_loader.efi ;
|
||||||
BuildAnybootImageEfi $(HAIKU_ANYBOOT) : $(baseMBR) : $(efiPartition) : $(HAIKU_CD_BOOT_IMAGE)
|
local efiPartition = esp.image ;
|
||||||
: $(HAIKU_IMAGE_NAME) ;
|
MakeLocate $(efiPartition) ;
|
||||||
|
BuildEfiSystemPartition $(efiPartition) : $(efiLoader) ;
|
||||||
|
BuildAnybootImageEfi $(HAIKU_ANYBOOT) : $(baseMBR)
|
||||||
|
: $(efiPartition) : $(HAIKU_CD_BOOT_IMAGE)
|
||||||
|
: $(HAIKU_IMAGE_NAME) ;
|
||||||
|
} else if $(HAIKU_ANYBOOT_LEGACY) = 1 {
|
||||||
|
BuildAnybootImage $(HAIKU_ANYBOOT) : $(baseMBR)
|
||||||
|
: $(HAIKU_CD_BOOT_IMAGE) : $(HAIKU_IMAGE_NAME) ;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
# TODO: this one seems to cause the build to fail each other run (caching?)
|
# TODO: this one seems to cause the build to fail each other run (caching?)
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ NotFile $(HAIKU_CD_BOOT_IMAGE_CONTAINER_NAME) ;
|
|||||||
|
|
||||||
# common extra files to put on the boot iso
|
# common extra files to put on the boot iso
|
||||||
local extras = README.html ;
|
local extras = README.html ;
|
||||||
|
SEARCH on $(extras) = [ FDirName $(HAIKU_TOP) data boot_cd ] ;
|
||||||
|
|
||||||
if $(TARGET_ARCH) = ppc {
|
if $(TARGET_ARCH) = ppc {
|
||||||
local elfloader = boot_loader_openfirmware ;
|
local elfloader = boot_loader_openfirmware ;
|
||||||
@@ -24,23 +25,31 @@ if $(TARGET_ARCH) = ppc {
|
|||||||
# HFS creator and application type mapping for mkisofs
|
# HFS creator and application type mapping for mkisofs
|
||||||
local hfsmaps = hfs.map ;
|
local hfsmaps = hfs.map ;
|
||||||
|
|
||||||
SEARCH on $(chrpscript) $(hfsmaps) $(extras) = [ FDirName $(HAIKU_TOP) data boot_cd ] ;
|
SEARCH on $(chrpscript) $(hfsmaps) $(extras)
|
||||||
|
= [ FDirName $(HAIKU_TOP) data boot_cd ] ;
|
||||||
|
|
||||||
BuildCDBootPPCImage $(HAIKU_CD_BOOT_IMAGE) : $(hfsmaps) : $(elfloader) : $(coffloader) : $(chrpscript) : $(extras) ;
|
BuildCDBootPPCImage $(HAIKU_CD_BOOT_IMAGE) : $(hfsmaps)
|
||||||
} else if $(HAIKU_ANYBOOT_LEGACY) = 1 {
|
: $(elfloader) : $(coffloader) : $(chrpscript) : $(extras) ;
|
||||||
BuildCDBootImage $(HAIKU_CD_BOOT_IMAGE) : $(HAIKU_BOOT_FLOPPY) : : $(extras) ;
|
|
||||||
|
|
||||||
SEARCH on $(extras) = [ FDirName $(HAIKU_TOP) data boot_cd ] ;
|
|
||||||
} else {
|
} else {
|
||||||
local efiLoader = haiku_loader.efi ;
|
# For other platforms, we have to check which bootloader is used. There
|
||||||
local efiPartition = esp.image ;
|
# can be multiple ones, making this a bit confusing.
|
||||||
MakeLocate $(efiPartition) : $(HAIKU_OUTPUT_DIR) ;
|
for platform in [ MultiBootSubDirSetup ] {
|
||||||
BuildEfiSystemPartition $(efiPartition) : $(efiLoader) ;
|
on $(platform) {
|
||||||
|
if $(TARGET_BOOT_PLATFORM) = efi {
|
||||||
|
local efiLoader = haiku_loader.efi ;
|
||||||
|
local efiPartition = esp.image ;
|
||||||
|
MakeLocate $(efiPartition) : $(HAIKU_OUTPUT_DIR) ;
|
||||||
|
BuildEfiSystemPartition $(efiPartition) : $(efiLoader) ;
|
||||||
|
|
||||||
BuildCDBootImage $(HAIKU_CD_BOOT_IMAGE) : $(HAIKU_BOOT_FLOPPY)
|
BuildCDBootImage $(HAIKU_CD_BOOT_IMAGE) : $(HAIKU_BOOT_FLOPPY)
|
||||||
: $(efiPartition) : $(extras) ;
|
: $(efiPartition) : $(extras) ;
|
||||||
|
|
||||||
SEARCH on $(extras) = [ FDirName $(HAIKU_TOP) data boot_cd ] ;
|
} else if $(HAIKU_ANYBOOT_LEGACY) = 1 {
|
||||||
|
BuildCDBootImage $(HAIKU_CD_BOOT_IMAGE) : $(HAIKU_BOOT_FLOPPY) :
|
||||||
|
: $(extras) ;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
NotFile haiku-boot-cd ;
|
NotFile haiku-boot-cd ;
|
||||||
|
|||||||
Reference in New Issue
Block a user