TODO revision 1.3
1o Emit everything (ioconf.*, Makefile, ...) per-attribute. 2 3o Generate modular(9) related information. Especially module dependency. 4 5o Rename "interface attribute" to "bus". 6 7 Instead of 8 9 define audiobus {} 10 attach audio at audiobus 11 12 Do like this 13 14 defbus audiobus {} 15 attach audio at audiobus 16 17o Sort objects in more reasonable order. 18 19 Put machdep.ko in the lowest address. uvm.ko and kern.ko follow. 20 21 Kill alphabetical sort (${OBJS:O} in sys/conf/Makefile.inc.kern. 22 23 Use ldscript. Do like this 24 25 .text : 26 AT (ADDR(.text) & 0x0fffffff) 27 { 28 *(.text.machdep.locore.entry) 29 *(.text.machdep.locore) 30 *(.text.machdep) 31 *(.text) 32 *(.text.*) 33 : 34 35 Kill linker definitions in sys/conf/Makefile.inc.kern. 36 37o Differentiate "options" and "flags"/"params". 38 39 "options" enables features by adding *.c files (via attributes). 40 41 "flags" and "params" are to change contents of *.c files. These don't add 42 *.c files to the result kernel, or don't build attributes (modules). 43 44o Make flags/params per attributes (modules). 45 46 Basically flags and params are cpp(1) #define's generated in opt_*.h. Make 47 them local to one attributes (modules). Flags/params which affects files 48 across attributes (modules) are possible, but should be discouraged. 49 50o Generate things only by definitions. 51 52 In the ideal dynamically modular world, "selection" will be done not at 53 compile time but at runtime. Users select their wanted modules, by 54 dynamically loading them. 55 56 This means that the system provides all choices; that is, build all modules 57 in the source tree. Necessary information is defined in the "definition" 58 part. 59 60o Split cfdata. 61 62 cfdata is pattern matching rules to enable devices at runtime device 63 auto-configuration. It is pure data and can (should) be generated separately 64 from the code. 65