Re: Announcing CML2, a replacement for the kbuild system

From: Eric S. Raymond (
Date: Wed May 31 2000 - 23:23:08 EST

Jeff Garzik <>:
> "Eric S. Raymond" wrote:
> > Yes. The existing CML2 code does this automatically. If you say
> >
> > cmlconfigure -DARM
> >
> > options for X86, SPARC, etc won't even be queried for. CML2 freezes
> > the other architecture symbols at N and uses a little theorem prover
> > to deduces from those what questions should not be asked.
> hmmm, this is completely different from the current system. The current
> system "knows" what architecture you are configuring. Users shouldn't
> have to specify a -D to get this behavior..

There's no magic there. The current system only knows because the
Makefile sets an ARCH symbol to one of the following:

alpha i386 m68k mips64 s390 sparc arm ia64 mips ppc sh sparc64

The Makefile then uses that to generate the name of the top-level config file
So this is not "completely different"; the only question is how and where to
do the following mapping:

alpha -DALPHA
i386 -DX86
m68k -DM68K
mips64 -DMIPS64
s390 -DS390
sparc -DSPARC32
arm -DARM
ia64 -DIA64
mips -DMIPS32
ppc -DPPC
sparc64 -DSPARC64

The following line does it...

PREDEF := -D$(shell uname -m | sed \
        -e s/i.86/x86/ \
        -e s/sun4u/sparc64/ \
        -e s/arm.*/arm/ \
        -e s/sa110/arm/ \
        -e s/sparc$$/sparc64/ \
        -e s/mips$$/mips64/ \
        -e s/sh$$/superh64/ \
        | tr "[a-z]" "[A-Z]")

> P.S. Can you package cml to extract into something other than the
> current directory? ie. extract the tarball into cml-x.y.z/*

Gak! I just violated my own practice guidelines! :-)

I'll fix.

		<a href="">Eric S. Raymond</a>

Faith may be defined briefly as an illogical belief in the occurrence of the improbable...A man full of faith is simply one who has lost (or never had) the capacity for clear and realistic thought. He is not a mere ass: he is actually ill. -- H. L. Mencken

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to Please read the FAQ at

This archive was generated by hypermail 2b29 : Wed Jun 07 2000 - 21:00:11 EST