Subject: Re: kern/12298: fairly impressive cross-compilation bogon in sys/lib/libsa/tftp.c
To: Todd Vierling <tv@wasabisystems.com>
From: None <itojun@iijlab.net>
List: netbsd-bugs
Date: 03/01/2001 09:16:08
>: #ifdef _STANDALONE
>: #include "/usr/include/arpa/tftp.h" /* XXX */
>: #else
>: #include <arpa/tftp.h>
>: #endif
>:
>: given that the code is typically compiled with _STANDALONE, that
>: pulls in the host's /usr/include/arpa/tftp.h.
>
>: unknown what the right solution is.  can't just include <arpa/tftp.h>,
>: even if the cross-compiler is built properly (i.e., with complete
>: NetBSD includes, etc.), because the code is typically compiled with
>: -nostdinc.
>
>The problem here is that relevant protocol includes are in src/include
>and not src/sys.  If there's kernel/standalone code that uses definitions
>from <arpa/*>, it's probably better to move the arpa/*.h files into src/sys.

	i still wonder why #ifdef _STANDALONE is needed.
	- native compilation should go fine with <arpa/tftp.h>
	- cross compilation should supply netbsd includes, so it should
	  go fine with <arpa/tftp.h>
	(i think the above is what the PR says)

itojun