[PATCH] GNU/KNetBSD support (with ChangeLog)

Jim Wilson wilson@specifixinc.com
Fri Dec 5 08:04:00 GMT 2003


Robert Millan wrote:
>>	* config/i386/knetbsd-gnu.h: New. i386-*-knetbsd-gnu definitions.
>>	* config.gcc: Add *-*-knetbsd*-gnu and i[34567]86-*-knetbsd*-gnu.

It looks like you took the existing config/i386/netbsd-elf.h file and 
then modified it to suit your needs.

However, I see that you are now including both netbsd-elf.h and 
knetbsd-gnu.h which means you are defining a lot of macros twice. 
Unless there is a good reason for this, you should delete all of the 
duplicate definitions out of knetbsd-gnu.h.  Only define the things you 
need to override netbsd-elf.h.  That will result in a smaller hopefully 
easier to maintain file.  This is more like what the existing 
kfreebsdgnu.h file does.

I see that the kfreebsd port created a config/kfreebsdgnu.h file to 
contain definitions that apply to all kfreebsd targets.  You might want 
to do the same for knetbsdgnu.  The config/kfreebsdgnu.h file holds a 
TARGET_OS_CPP_BUILTINS macro which is the right place to put this.  It 
also has a TARGET_CPU_CPP_BUILTINS macro which obviously belongs in the 
i386 directory, so don't copy that mistake.

The only other issue I have is with copyright assignments.  We need one 
for gcc on file for you before we can accept a patch from you.  I can't 
verify this myself at the moment.
-- 
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com



More information about the Gcc mailing list