2 * This program is free software; you can redistribute it and/or
3 * modify it under the terms of the GNU General Public License as
4 * published by the Free Software Foundation; either version 2, or (at
5 * your option) any later version.
8 FILE_LICENCE ( GPL2_OR_LATER );
10 #include <config/general.h>
11 #include <config/console.h>
15 * Configuration options
17 * This file contains macros that pull various objects into the link
18 * based on definitions in configuration header files. Ideally it
19 * should be the only place in gPXE where one might need to use #ifdef
20 * for compile-time options.
22 * In the fairly common case where an object should only be considered
23 * for inclusion if the subsystem it depends on is present, its
24 * configuration macros should be placed in a file named
25 * <tt>config_<i>subsystem</i>.c</tt>, where @e subsystem is the
26 * object basename of the main source file for that subsystem. The
27 * build system will pull in that file if @c subsystem.c is included
28 * in the final gPXE executable built.
32 * Build ID string calculations
37 #define XSTR(s) STR(s)
41 #include "config/.buildserial.h"
42 #define BUILD_SERIAL_STR " #" XSTR(BUILD_SERIAL_NUM)
44 #define BUILD_SERIAL_STR ""
48 #define BUILD_ID_STR " " BUILD_ID
50 #define BUILD_ID_STR ""
53 #if defined(BUILD_ID) || defined(BUILD_SERIAL)
54 #define BUILD_STRING " [build" BUILD_ID_STR BUILD_SERIAL_STR "]"
56 #define BUILD_STRING ""
60 * Drag in all requested console types
65 REQUIRE_OBJECT ( bios_console );
68 REQUIRE_OBJECT ( serial_console );
70 #ifdef CONSOLE_DIRECT_VGA
71 REQUIRE_OBJECT ( video_subr );
74 REQUIRE_OBJECT ( btext );
77 REQUIRE_OBJECT ( pc_kbd );
80 REQUIRE_OBJECT ( syslog );
83 REQUIRE_OBJECT ( efi_console );
87 * Drag in all requested network protocols
91 REQUIRE_OBJECT ( ipv4 );
95 * Drag in all requested download protocols
98 #ifdef DOWNLOAD_PROTO_TFTP
99 REQUIRE_OBJECT ( tftp );
101 #ifdef DOWNLOAD_PROTO_NFS
102 REQUIRE_OBJECT ( nfs );
104 #ifdef DOWNLOAD_PROTO_HTTP
105 REQUIRE_OBJECT ( http );
107 #ifdef DOWNLOAD_PROTO_HTTPS
108 REQUIRE_OBJECT ( https );
110 #ifdef DOWNLOAD_PROTO_FTP
111 REQUIRE_OBJECT ( ftp );
113 #ifdef DOWNLOAD_PROTO_TFTM
114 REQUIRE_OBJECT ( tftm );
116 #ifdef DOWNLOAD_PROTO_SLAM
117 REQUIRE_OBJECT ( slam );
121 * Drag in all requested SAN boot protocols
124 #ifdef SANBOOT_PROTO_ISCSI
125 REQUIRE_OBJECT ( iscsiboot );
127 #ifdef SANBOOT_PROTO_AOE
128 REQUIRE_OBJECT ( aoeboot );
130 #ifdef SANBOOT_PROTO_IB_SRP
131 REQUIRE_OBJECT ( ib_srpboot );
135 * Drag in all requested resolvers
139 REQUIRE_OBJECT ( dns );
142 REQUIRE_OBJECT ( nmb );
146 * Drag in all requested image formats
150 REQUIRE_OBJECT ( nbi );
153 REQUIRE_OBJECT ( elfboot );
156 REQUIRE_OBJECT ( freebsd );
158 #ifdef IMAGE_MULTIBOOT
159 REQUIRE_OBJECT ( multiboot );
162 REQUIRE_OBJECT ( aout );
165 REQUIRE_OBJECT ( wince );
168 REQUIRE_OBJECT ( pxe_image );
171 REQUIRE_OBJECT ( script );
174 REQUIRE_OBJECT ( bzimage );
176 #ifdef IMAGE_ELTORITO
177 REQUIRE_OBJECT ( eltorito );
180 REQUIRE_OBJECT ( comboot );
181 REQUIRE_OBJECT ( com32 );
182 REQUIRE_OBJECT ( comboot_call );
183 REQUIRE_OBJECT ( com32_call );
184 REQUIRE_OBJECT ( com32_wrapper );
185 REQUIRE_OBJECT ( comboot_resolv );
188 REQUIRE_OBJECT ( efi_image );
192 * Drag in all requested commands
196 REQUIRE_OBJECT ( autoboot_cmd );
199 REQUIRE_OBJECT ( nvo_cmd );
202 REQUIRE_OBJECT ( config_cmd );
205 REQUIRE_OBJECT ( ifmgmt_cmd );
208 REQUIRE_OBJECT ( route_cmd );
211 REQUIRE_OBJECT ( image_cmd );
214 REQUIRE_OBJECT ( dhcp_cmd );
217 REQUIRE_OBJECT ( sanboot_cmd );
220 REQUIRE_OBJECT ( login_cmd );
223 REQUIRE_OBJECT ( time_cmd );
226 REQUIRE_OBJECT ( digest_cmd );
229 REQUIRE_OBJECT ( pxe_cmd );
233 * Drag in miscellaneous objects
237 REQUIRE_OBJECT ( nulltrap );
240 REQUIRE_OBJECT ( gdbidt );
241 REQUIRE_OBJECT ( gdbserial );
242 REQUIRE_OBJECT ( gdbstub_cmd );
245 REQUIRE_OBJECT ( gdbidt );
246 REQUIRE_OBJECT ( gdbudp );
247 REQUIRE_OBJECT ( gdbstub_cmd );
251 * Drag in objects that are always required, but not dragged in via
252 * symbol dependencies.
255 REQUIRE_OBJECT ( device );
256 REQUIRE_OBJECT ( embedded );