1# This file defines what ends up in the network boot archive and it executes the 2# rules building the archive. 3 4 5SYSTEM_NETWORK_DEVICES = ethernet loopback ; 6SYSTEM_NETWORK_DATALINK_PROTOCOLS = ethernet_frame <module>arp loopback_frame ; 7SYSTEM_NETWORK_PROTOCOLS = ipv4 tcp udp icmp unix ; 8 9SYSTEM_ADD_ONS_DRIVERS_NET = [ FFilterByBuildFeatures 10 x86 @{ 11 3com atheros813x atheros81xx 12 broadcom440x broadcom570x ipro1000 13 rtl8139 rtl81xx 14 via_rhine ipro100 nforce 15 marvell_yukon sis900 syskonnect 16 attansic_l2 17 }@ # x86 18 19 etherpci pegasus usb_ecm wb840 20] ; 21SYSTEM_ADD_ONS_BUS_MANAGERS = [ FFilterByBuildFeatures 22 pci isa@x86 ata 23 scsi config_manager agp_gart 24] ; 25SYSTEM_ADD_ONS_FILE_SYSTEMS = bfs packagefs ; 26 27 28# modules 29AddFilesToNetBootArchive system add-ons kernel bus_managers 30 : $(SYSTEM_ADD_ONS_BUS_MANAGERS) ; 31AddFilesToNetBootArchive system add-ons kernel busses agp_gart 32 : <agp_gart>intel@x86 ; 33AddFilesToNetBootArchive system add-ons kernel busses ide 34 : generic_ide_pci ide_isa@x86 silicon_image_3112 ; 35AddFilesToNetBootArchive system add-ons kernel busses scsi 36 : ahci ; 37AddFilesToNetBootArchive system add-ons kernel console 38 : vga_text ; 39AddFilesToNetBootArchive system add-ons kernel file_systems 40 : $(SYSTEM_ADD_ONS_FILE_SYSTEMS) ; 41AddFilesToNetBootArchive system add-ons kernel generic 42 : ata_adapter locked_pool scsi_periph ; 43AddFilesToNetBootArchive system add-ons kernel partitioning_systems 44 : intel session ; 45AddFilesToNetBootArchive system add-ons kernel interrupt_controllers 46 : openpic@ppc ; 47 48if $(TARGET_ARCH) = x86 { 49 AddFilesToNetBootArchive system add-ons kernel cpu 50 : generic_x86 ; 51} 52 53# drivers 54AddNewDriversToNetBootArchive disk scsi : scsi_cd scsi_disk ; 55#AddDriversToNetBootArchive disk virtual : nbd ; 56AddDriversToNetBootArchive disk virtual : remote_disk ; 57AddDriversToNetBootArchive net : $(SYSTEM_ADD_ONS_DRIVERS_NET) ; 58 59# kernel 60AddFilesToNetBootArchive system 61 : <revisioned>kernel_$(TARGET_ARCH) ; 62 63# scripts and data files 64 65local driverSettingsFiles = <driver-settings>kernel ; 66SEARCH on $(driverSettingsFiles) 67 = [ FDirName $(HAIKU_TOP) data settings kernel drivers ] ; 68AddFilesToNetBootArchive home config settings kernel drivers 69 : $(driverSettingsFiles) ; 70 71# add-ons 72AddFilesToNetBootArchive system add-ons kernel network 73 : stack ; 74AddFilesToNetBootArchive system add-ons kernel network devices 75 : $(SYSTEM_NETWORK_DEVICES) ; 76AddFilesToNetBootArchive 77 system add-ons kernel network datalink_protocols 78 : $(SYSTEM_NETWORK_DATALINK_PROTOCOLS) ; 79AddFilesToNetBootArchive system add-ons kernel network ppp 80 : $(SYSTEM_NETWORK_PPP) ; 81AddFilesToNetBootArchive 82 system add-ons kernel network protocols 83 : $(SYSTEM_NETWORK_PROTOCOLS) ; 84 85# boot module links 86AddBootModuleSymlinksToNetBootArchive 87 $(SYSTEM_ADD_ONS_BUS_MANAGERS) 88 ahci generic_ide_pci ide_isa@x86 silicon_image_3112 89 $(SYSTEM_ADD_ONS_FILE_SYSTEMS) 90 ata_adapter locked_pool scsi_periph 91 intel session 92 openpic@ppc 93 generic_x86@x86 94# nbd 95 remote_disk 96 $(SYSTEM_ADD_ONS_DRIVERS_NET) 97 stack 98 $(SYSTEM_NETWORK_DEVICES) 99 $(SYSTEM_NETWORK_DATALINK_PROTOCOLS) 100 $(SYSTEM_NETWORK_PPP) 101 $(SYSTEM_NETWORK_PROTOCOLS) 102; 103 104 105#pragma mark - Build The Archive 106 107# archive target 108HAIKU_NET_BOOT_ARCHIVE = haiku-netboot.tgz ; 109MakeLocate $(HAIKU_NET_BOOT_ARCHIVE) : $(HAIKU_OUTPUT_DIR) ; 110 111# the pseudo target all archive contents is attached to 112NotFile $(HAIKU_NET_BOOT_ARCHIVE_CONTAINER_NAME) ; 113 114# prepare the script that initializes the shell variables 115local initVarsScript = <NetBootArchive>haiku-netboot-init-vars ; 116local script = $(initVarsScript) ; 117MakeLocate $(script) : $(HAIKU_OUTPUT_DIR) ; 118Always $(script) ; 119 120AddVariableToScript $(script) : tmpDir : $(HAIKU_TMP_DIR) ; 121AddVariableToScript $(script) : addBuildCompatibilityLibDir 122 : "export $(HOST_ADD_BUILD_COMPATIBILITY_LIB_DIR)" ; 123AddTargetVariableToScript $(script) : <build>copyattr ; 124 125# create the other scripts 126local makeDirsScript = <NetBootArchive>haiku-netboot-make-dirs ; 127local copyFilesScript = <NetBootArchive>haiku-netboot-copy-files ; 128MakeLocate $(makeDirsScript) $(copyFilesScript) : $(HAIKU_OUTPUT_DIR) ; 129 130CreateNetBootArchiveMakeDirectoriesScript $(makeDirsScript) ; 131CreateNetBootArchiveCopyFilesScript $(copyFilesScript) ; 132 133# build the archive 134 135BuildNetBootArchive $(HAIKU_NET_BOOT_ARCHIVE) : 136 $(initVarsScript) 137 $(makeDirsScript) 138 $(copyFilesScript) 139; 140 141# remove the scripts we have generated 142RmTemps $(HAIKU_NET_BOOT_ARCHIVE) : 143 $(initVarsScript) 144 $(makeDirsScript) 145 $(copyFilesScript) 146; 147 148NotFile haiku-netboot-archive ; 149Depends haiku-netboot-archive : $(HAIKU_NET_BOOT_ARCHIVE) ; 150