Subject: Re: Compiling the system with different options.
To: Christos Zoulas <>
From: Luke Mewburn <>
List: tech-userlevel
Date: 11/16/2004 11:19:46
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mon, Nov 15, 2004 at 05:49:12PM -0500, Christos Zoulas wrote:
  | There was a recent PR mentioning that right now there are too many opti=
  | hard-coded in the Makefiles and we cannot easily turn them on and off.
  | The example in the PR was -DINET6, but there are many more.

Such as?
INET6 is one of the few remaining ones to fix AFAICT.

  | We also commonly specify libraries in the Makefiles as:
  | .if ${USE_SKEY} !=3D "no"
  | LDADD +=3D -lskey
  | .endif
  | I suggest that we change all this to be:
  | This way we achieve the following:
  | 	- the Makefiles become simplified; no more conditionals
  | 	- the variable handling is symmetric; all variables are treated
  | 	  the same way.
  | 	- we don't expose implementation specific information such as -lskey.
  | All the magic is handled in We can start with -DINET6 -DSKEY
  | etc, which are low hanging fruit and I have a patch for them already,
  | and then become more ambitious to fix the rest.
  | What do you think?

I'm not convinced (yet): it doesn't scale well and may not save _that_
much effort given the number of special cases.
E.g, see USE_YP in usr.bin/passwd/Makefile, or the various different
ways that the KERBEROS{,5} knobs enable extra libraries and defines.

I also don't like the namespace pollution for applications.
At a minimum I think the CPPFLAGS_foo variable should instead be
	CPPFLAGS_foo?=3D -D_USE_foo

I need to consider this more...

Content-Type: application/pgp-signature
Content-Disposition: inline

Version: GnuPG v1.2.6 (NetBSD)