Compiling kernel/modules without INET?

Matt Emmerton matt at gsicomp.on.ca
Sun Jan 1 22:12:51 PST 2006


Howdy,

One of my new years resolutions was to become a bit more masochistic, so I
set out to see if I could build a kernel (and modules) without "options
INET" on HEAD.

This works flawlessly for the kernel part, but there are tons of issues when
building modules -- various problems encountered during "make depend" and
"make".

So far there appear to be four different classes of errors:
1) Failures during "make depend" due to #error directives hit when INET is
not defined.
2) #includes which are always needed but are only pulled in (implicitly)
when INET is defined
3) Small blocks of code (variable declarations and tests) which are not
wrapped with #ifdef INET (or other #defines), or simply wrapped with the
wrong #ifdef
4) Larger messes such as GRE's hard-coded dependence on INET; SLIP/PPP's
dependence on packet compress code, etc.

I have what I think are valid fixes for the first 3 issues, but I know I'm
just making a mess of things to resolve the last issue.

Before I spit and polish these patches for public consumption, I want to
know if this is even a worthy project.  I know there are benefits simply
because we should "do the right thing", but I'm sure I'm wading into murky
waters.  Any guidance would be appreciated.

Regards,
--
Matt Emmerton



More information about the freebsd-hackers mailing list