).
This will make the interface/implementation boundaries clearer,
and once propagated throughout the system, will make the build
environment slightly cleaner as well.
When creating new local header files,
I now include them without
specifying the directory name - let make and GCC hunt them down.
For example, say `#include "foo.h"' instead of `#include "kern/foo.h"'.
This allows more-specific header files to override less-specific files
automatically, just like .c files already can. Separate include file
namespaces are pretty much useless in Mach anyway, because their
corresponding object files all get thrown into one object directory
and therefore have to have unique names. Having separate .h
namespaces but a single .c namespace is just an inconsistency without
any real benefit. In any case, namespace crowding should be less and less
of a problem as the microkernel becomes more modular and more "micro".
NOTE: this change only applies to local header files:
public header files such as should still be included
by specifying the full directory name.
Pointer-to-structure types:
The web of cross-includes in the current Mach source is ridiculously huge,
and is mostly due to the convention of using typedef'd names for
pointers to structures (e.g. `ipc_port_t' instead of `struct ipc_port').
I'm working on cutting down the web (and therefore make compiles go faster)
by changing pointer references to the `struct' form instead of the `_t' form
as needed within header files, so one file doesn't need to include another
just because it uses a pointer to another structure.
History lists:
No more history lists embedded in each source file. They just take a
huge amount of space and don't really provide any more information than a single
GNU-style ChangeLog does. Also, they make merges more difficult
by creating additional spurrious modifications in source files
that often tend to conflict.
#ifdefs are Evil:
I'm trying to avoid putting any machine-dependent #ifdef's (e.g. #ifdef i386)
in machine-independent code. In the new build environment, where any
machine-independent file can be modified or overridden by machine-dependent
code, there is really no longer an excuse for machine-dependent #ifdef's.
If you need to put machine-dependent #ifdef's in machine-independent code,
then that code isn't really machine-independent, is it?