1*77b1fd22SAxel DörflerSubDir HAIKU_TOP src tests system boot loader ; 2*77b1fd22SAxel Dörfler 3*77b1fd22SAxel DörflerUsePrivateHeaders [ FDirName kernel ] ; 4*77b1fd22SAxel DörflerUsePrivateHeaders [ FDirName kernel disk_device_manager ] ; 5*77b1fd22SAxel DörflerUsePrivateHeaders [ FDirName storage ] ; 6*77b1fd22SAxel DörflerUsePrivateHeaders [ FDirName shared ] ; 7*77b1fd22SAxel DörflerSubDirHdrs $(HAIKU_TOP) headers private kernel arch $(TARGET_ARCH) ; 8*77b1fd22SAxel DörflerSubDirHdrs $(HAIKU_TOP) src system boot loader ; 9*77b1fd22SAxel Dörfler 10*77b1fd22SAxel Dörfler# we need to redefine certain calls in the boot loader so that 11*77b1fd22SAxel Dörfler# they will really be used instead of their POSIX counterparts 12*77b1fd22SAxel Dörfler# in libroot.so 13*77b1fd22SAxel Dörfler 14*77b1fd22SAxel DörflerObjectDefines 15*77b1fd22SAxel Dörfler # boot loader 16*77b1fd22SAxel Dörfler main.cpp 17*77b1fd22SAxel Dörfler vfs.cpp 18*77b1fd22SAxel Dörfler partitions.cpp 19*77b1fd22SAxel Dörfler RootFileSystem.cpp 20*77b1fd22SAxel Dörfler elf.cpp 21*77b1fd22SAxel Dörfler menu.cpp 22*77b1fd22SAxel Dörfler loader.cpp 23*77b1fd22SAxel Dörfler kernel_args.cpp 24*77b1fd22SAxel Dörfler load_driver_settings.cpp 25*77b1fd22SAxel Dörfler 26*77b1fd22SAxel Dörfler # other 27*77b1fd22SAxel Dörfler platform_menu.cpp 28*77b1fd22SAxel Dörfler driver_settings.c 29*77b1fd22SAxel Dörfler 30*77b1fd22SAxel Dörfler # partitions 31*77b1fd22SAxel Dörfler amiga_rdb.cpp 32*77b1fd22SAxel Dörfler apple.cpp 33*77b1fd22SAxel Dörfler intel.cpp 34*77b1fd22SAxel Dörfler PartitionMap.cpp 35*77b1fd22SAxel Dörfler PartitionMapParser.cpp 36*77b1fd22SAxel Dörfler : 37*77b1fd22SAxel Dörfler read_pos=boot_read_pos fstat=boot_fstat open=boot_open close=boot_close main=boot_main 38*77b1fd22SAxel Dörfler ; 39*77b1fd22SAxel Dörfler 40*77b1fd22SAxel Dörfler{ 41*77b1fd22SAxel Dörfler local defines = 42*77b1fd22SAxel Dörfler _BOOT_MODE 43*77b1fd22SAxel Dörfler BOOT_ARCH=\\\"$(TARGET_ARCH)\\\" 44*77b1fd22SAxel Dörfler # the boot loader test application will try to load the BeOS kernel 45*77b1fd22SAxel Dörfler # from a supported partition/file system 46*77b1fd22SAxel Dörfler 47*77b1fd22SAxel Dörfler BOOT_SUPPORT_PARTITION_AMIGA 48*77b1fd22SAxel Dörfler BOOT_SUPPORT_PARTITION_APPLE 49*77b1fd22SAxel Dörfler BOOT_SUPPORT_PARTITION_INTEL 50*77b1fd22SAxel Dörfler 51*77b1fd22SAxel Dörfler BOOT_SUPPORT_FILE_SYSTEM_BFS 52*77b1fd22SAxel Dörfler BOOT_SUPPORT_FILE_SYSTEM_AMIGA_FFS 53*77b1fd22SAxel Dörfler BOOT_SUPPORT_FILE_SYSTEM_TARFS 54*77b1fd22SAxel Dörfler ; 55*77b1fd22SAxel Dörfler 56*77b1fd22SAxel Dörfler defines = [ FDefines $(defines) ] ; 57*77b1fd22SAxel Dörfler 58*77b1fd22SAxel Dörfler if $(OS) = "LINUX" { 59*77b1fd22SAxel Dörfler } else { 60*77b1fd22SAxel Dörfler #SubDirC++Flags $(defines) -DHAVE_READ_POS=1 -fcheck-memory-usage -D_NO_INLINE_ASM ; 61*77b1fd22SAxel Dörfler SubDirC++Flags $(defines) -DHAVE_READ_POS=1 -D_NO_INLINE_ASM ; 62*77b1fd22SAxel Dörfler } 63*77b1fd22SAxel Dörfler} 64*77b1fd22SAxel Dörfler 65*77b1fd22SAxel DörflerSimpleTest BootLoaderTest : 66*77b1fd22SAxel Dörfler # userland bindings 67*77b1fd22SAxel Dörfler platform_start.cpp 68*77b1fd22SAxel Dörfler platform_debug.cpp 69*77b1fd22SAxel Dörfler platform_devices.cpp 70*77b1fd22SAxel Dörfler platform_heap.cpp 71*77b1fd22SAxel Dörfler platform_menu.cpp 72*77b1fd22SAxel Dörfler platform_misc.cpp 73*77b1fd22SAxel Dörfler platform_mmu.cpp 74*77b1fd22SAxel Dörfler Handle.cpp 75*77b1fd22SAxel Dörfler 76*77b1fd22SAxel Dörfler # boot loader 77*77b1fd22SAxel Dörfler main.cpp 78*77b1fd22SAxel Dörfler vfs.cpp 79*77b1fd22SAxel Dörfler partitions.cpp 80*77b1fd22SAxel Dörfler RootFileSystem.cpp 81*77b1fd22SAxel Dörfler elf.cpp 82*77b1fd22SAxel Dörfler menu.cpp 83*77b1fd22SAxel Dörfler loader.cpp 84*77b1fd22SAxel Dörfler kernel_args.cpp 85*77b1fd22SAxel Dörfler load_driver_settings.cpp 86*77b1fd22SAxel Dörfler 87*77b1fd22SAxel Dörfler # partitioning systems 88*77b1fd22SAxel Dörfler amiga_rdb.cpp 89*77b1fd22SAxel Dörfler apple.cpp 90*77b1fd22SAxel Dörfler intel.cpp 91*77b1fd22SAxel Dörfler PartitionMap.cpp 92*77b1fd22SAxel Dörfler PartitionMapParser.cpp 93*77b1fd22SAxel Dörfler 94*77b1fd22SAxel Dörfler # utility functions - Dano has a strlcpy() function in libroot.so, while R5 has not 95*77b1fd22SAxel Dörfler list.c 96*77b1fd22SAxel Dörfler strlcat.c 97*77b1fd22SAxel Dörfler strlcpy.c 98*77b1fd22SAxel Dörfler driver_settings.c 99*77b1fd22SAxel Dörfler 100*77b1fd22SAxel Dörfler : boottest_bfs.a boottest_amiga_ffs.a boottest_tarfs.a libz.a 101*77b1fd22SAxel Dörfler ; 102*77b1fd22SAxel Dörfler 103*77b1fd22SAxel Dörfler# Tell Jam where to find the utility sources 104*77b1fd22SAxel Dörfler 105*77b1fd22SAxel DörflerSEARCH on [ FGristFiles list.c ] 106*77b1fd22SAxel Dörfler = [ FDirName $(HAIKU_TOP) src system kernel util ] ; 107*77b1fd22SAxel Dörfler 108*77b1fd22SAxel DörflerSEARCH on [ FGristFiles strlcat.c strlcpy.c ] 109*77b1fd22SAxel Dörfler = [ FDirName $(HAIKU_TOP) src system libroot posix string ] ; 110*77b1fd22SAxel Dörfler 111*77b1fd22SAxel DörflerSEARCH on [ FGristFiles driver_settings.c ] 112*77b1fd22SAxel Dörfler = [ FDirName $(HAIKU_TOP) src system libroot os ] ; 113*77b1fd22SAxel Dörfler 114*77b1fd22SAxel DörflerSEARCH on [ FGristFiles 115*77b1fd22SAxel Dörfler main.cpp vfs.cpp partitions.cpp 116*77b1fd22SAxel Dörfler heap.cpp RootFileSystem.cpp 117*77b1fd22SAxel Dörfler elf.cpp menu.cpp loader.cpp 118*77b1fd22SAxel Dörfler kernel_args.cpp load_driver_settings.cpp 119*77b1fd22SAxel Dörfler ] = [ FDirName $(HAIKU_TOP) src system boot loader ] ; 120*77b1fd22SAxel Dörfler 121*77b1fd22SAxel Dörfler# partitioning system modules 122*77b1fd22SAxel Dörfler 123*77b1fd22SAxel DörflerSEARCH on [ FGristFiles amiga_rdb.cpp ] 124*77b1fd22SAxel Dörfler = [ FDirName $(HAIKU_TOP) src add-ons kernel partitioning_systems amiga ] ; 125*77b1fd22SAxel Dörfler 126*77b1fd22SAxel DörflerSEARCH on [ FGristFiles apple.cpp ] 127*77b1fd22SAxel Dörfler = [ FDirName $(HAIKU_TOP) src add-ons kernel partitioning_systems apple ] ; 128*77b1fd22SAxel Dörfler 129*77b1fd22SAxel DörflerSEARCH on [ FGristFiles intel.cpp PartitionMap.cpp PartitionMapParser.cpp ] 130*77b1fd22SAxel Dörfler = [ FDirName $(HAIKU_TOP) src add-ons kernel partitioning_systems intel ] ; 131*77b1fd22SAxel Dörfler 132*77b1fd22SAxel Dörfler 133*77b1fd22SAxel DörflerSubInclude HAIKU_TOP src tests system boot loader file_systems ; 134