Subject: Re: No "amiga" define in default compiler...
To: Stephen J. Roznowski <sjr@zombie.ncsc.mil>
From: Chris Hopps <chopps@emunix.emich.edu>
List: amiga-dev
Date: 03/10/1994 00:51:14
> 
> > > > The default compiler built from the sun-lamp sources
> > > > does not define "amiga". Can/Should this be fixed?
> > > > 
> > > 	I talked about this with Chris Hopps and he said, and I agreed
> > > 	with him, the answer to this question is no. Any code that
> > > 	NEEDS to know it's on an Amiga should put a special if case in
> > > 	the Makefile, see Makefile in libkvm for details.
> > 
> > exatcly.
> 
> I'm not sure that I completely agree with you on this issue....
> 
> First, you are "forcing" me to buy into the "netbsd makefiles",
> suppose that I'm using something else....

I don't understand what you mean by "netbsd makefiles".  Anytime you
want to define amiga add "-Damiga" to you CFLAGS or whatever it
need not be imbeded in the gcc invoker.

> > > 	places that amiga should be defined are in kernel related
> > > 	issues and with the exception of libkvm and the disklabel stuff they
> > > 	should be under sys/arch/amiga. Hopefully the other m68k ports will
> > > 	adopt the cpu040 variable in their kernels and we can
> > > 	drop the special case in libkvm soon.
> 
> There are other places besides the kernel where it might be useful
> to know that I'm running on an Amiga during the compile....

There may be other places I am not saying there isn't config comes to mind.
However by expcitly defining amiga (-Damiga or in netbsd's case -D${MACHINE})
in the Makefile lets everyone know that something in this "program"
depends upon the machine type

> -SR

Chris.

BTW anyone seen the latest term? it includes a check for -Damiga
*which it should not* nothing in term uses or needs this knowledge.  I
am sure that whoever did it didn't understand this and its not a rip
on him/her heck I didn't spend the time to send patches...it is a
misuse however.  (It should have been #ifdef __NetBSD__)

BTW I hope everyone knows that becuase of this "hiding" of the mchine
type (and countless more important reasons) amiga binaries run on mac
NetBSD machines.  *This* is the goal.  In most cases We don't care
that its an amiga we care that is has a 680x0 chip in it and its
running NetBSD.  Thats it.  The kenrel takes care of hiding the differences.

Chris. (again :^)


------------------------------------------------------------------------------