Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 19 Dec 2001 09:07:12 +0100
From:      Joerg Wunsch <j@uriah.heep.sax.de>
To:        Ruslan Ermilov <ru@FreeBSD.org>
Cc:        cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Subject:   Re: cvs commit: src/sys/isa fd.c
Message-ID:  <20011219090712.G97821@uriah.heep.sax.de>
In-Reply-To: <20011219095119.B93645@sunbay.com>; from ru@FreeBSD.org on Wed, Dec 19, 2001 at 09:51:19AM %2B0200
References:  <200112182216.fBIMGX179954@freefall.freebsd.org> <20011219095119.B93645@sunbay.com>

next in thread | previous in thread | raw e-mail | index | archive | help
As Ruslan Ermilov wrote:

> This is because _MACHINE_ARCH is a bogus define.
> 
> On i386's, ``cpp -dM /dev/null'' shows the following:

Ah, that's the command i've been looking for...

> On alphas, ``cpp -dM /dev/null'' doesn't define "alpha" as 1,
> so _MACHINE_ARCH is ``alpha'' (not a string constant!), and
> i386 is not defined either, so

Well, i think that should be fixed then.

> What you should be actually testing is MACHINE_ARCH, but

No, since string constants cannot be compared in cpp.

> it's still not suitable in this case, because MACHINE_ARCH
> is "i386" on PC98.  Moreover, MACHINE is also "i386" on
> PC98.

OK, so PC98 is really specific and needs to be excluded (sigh), but
IMHO we should really fix _MACHINE and _MACHINE_ARCH to generate
something that is useful for a cpp conditional.  If we don't, there's
no purpose to pollute the namespace with two pointless macros.

-- 
cheers, J"org               .-.-.   --... ...--   -.. .  DL8DTL

http://www.sax.de/~joerg/                        NIC: JW11-RIPE
Never trust an operating system you don't have sources for. ;-)

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20011219090712.G97821>