Subject: kern/19607: libsa build broken due too missing arpa/tftp.h in src/sys
To: None <gnats-bugs@gnats.netbsd.org>
From: None <pr200212@veego.de>
List: netbsd-bugs
Date: 12/30/2002 17:50:07
>Number:         19607
>Category:       kern
>Synopsis:       libsa build broken due too missing arpa/tftp.h in src/sys
>Confidential:   no
>Severity:       non-critical
>Priority:       high
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Dec 30 08:51:00 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     Bernd Ernesti
>Release:        NetBSD 1.6K src 30-Dec-2002
>Organization:
	
>Environment:
System: NetBSD 1.6K
Architecture: i386
Machine: i386
>Description:
	IMHO this is also broken on other archs who use libsa, so I use
	kern and not port-i386 for it.

	Compiling src/sys/arch/i386/stand fails due a missing include file:

cc -O2 -Wall -Os -mcpu=i386 -ffreestanding  -Werror -I/src/sys/arch/i386/stand/netboot/3c509/../../../../..//lib/libsa -DSUPPORT_BOOTP -DSUPPORT_DHCP -DSUPPORT_TFTP -DBOOTROM -DRELOC=0x90000 -nostdinc -I/src/sys/arch/i386/stand/netboot/3c509/obj.i386 -I/src/sys/arch/i386/stand/netboot/3c509/../../../../../ -I/src/sys/arch/i386/stand/netboot/3c509/../../../../..//arch/i386/stand/lib -I/src/sys/arch/i386/stand/netboot/3c509/../../../../..//lib/libsa -D_STANDALONE -DHEAP_START=0x10000 -DHEAP_LIMIT=0x40000 -DNFS_NOSYMLINK -DUDP_NO_CKSUM  -DCOMPAT_UFS    -c /src/sys/arch/i386/stand/netboot/3c509/../../../../..//lib/libsa/tftp.c
/src/sys/arch/i386/stand/netboot/3c509/../../../../..//lib/libsa/tftp.c:62: arpa/tftp.h: No such file or directory
*** Error code 1

	There is only a tftp.h under sys/lib/libsa, but thats not good enough
	for sys/lib/libsa/tftp.c.

	Now, the strange thing is, that sys/lib/libsa/tftp.c was changed more
	then 3 month ago and nobody had problems with it yet. The reason for that
	seems to be that everyone is setting DESTDIR somewhere, because if I do
	that I will get the following compile line:

cc -O2 -Wall -Os -mcpu=i386 -ffreestanding  -Werror -I/src/sys/arch/i386/stand/netboot/3c509/../../../../..//lib/libsa -DSUPPORT_BOOTP -DSUPPORT_DHCP -DSUPPORT_TFTP -DBOOTROM -DRELOC=0x90000 -nostdinc -I/src/sys/arch/i386/stand/netboot/3c509/obj.i386 -I/src/sys/arch/i386/stand/netboot/3c509/../../../../../ -I/src/sys/arch/i386/stand/netboot/3c509/../../../../..//arch/i386/stand/lib -I/src/sys/arch/i386/stand/netboot/3c509/../../../../..//lib/libsa -D_STANDALONE -nostdinc -isystem //usr/include -DHEAP_START=0x10000 -DHEAP_LIMIT=0x40000 -DNFS_NOSYMLINK -DUDP_NO_CKSUM  -DCOMPAT_UFS  -nostdinc -isystem //usr/include  -c /src/sys/arch/i386/stand/netboot/3c509/../../../../..//lib/libsa/tftp.c

	Please note the '-nostdinc -isystem //usr/include' which is bogus because this
	should never be here. Everything under sys/arch/*/stand has to only use files
	from src/sys
>How-To-Repeat:
	Compile src/sys/arch/i386/stand without setting DESTDIR
>Fix:
	Add the missing definitions from /usr/include/arpa/tftp.h?
	And investigate why /usr/include is added when using DESTDIR.
>Release-Note:
>Audit-Trail:
>Unformatted: