Subject: Foreign Build w/ USE_NEW_TOOLCHAIN: kdump/ktruss Might Not Build
To: None <tech-toolchain@netbsd.org>
From: Chris Jepeway <jepeway@blasted-heath.com>
List: tech-toolchain
Date: 09/22/2001 23:59:08
The list of ioctls that kdump knows how to decode is built using
the shell script usr.bin/kdump/mkioctls.  mkioctls isn't being
invoked correctly from usr.bin/kdump/Makefile.ioctl-c: it will use
the native cc and it won't see DESTDIR.  This affects ktruss, too.

Simple patch follows.

Chris <jepeway@blasted-heath.com>.

Index: usr.bin/kdump/Makefile.ioctl-c
===================================================================
RCS file: /cvsroot/basesrc/usr.bin/kdump/Makefile.ioctl-c,v
retrieving revision 1.2
diff -u -r1.2 Makefile.ioctl-c
--- Makefile.ioctl-c	2000/07/27 11:51:14	1.2
+++ Makefile.ioctl-c	2001/09/23 03:01:47
@@ -1,7 +1,7 @@
 #	$NetBSD: Makefile.ioctl-c,v 1.2 2000/07/27 11:51:14 mrg Exp $
 
 ioctl.c: mkioctls ${DESTDIR}/usr/include/sys/ioctl.h ${DESTDIR}/usr/include/sys/ioctl_compat.h
-	/bin/sh ${.CURDIR}/../kdump/mkioctls ${DESTDIR}/usr/include/sys/ioctl.h \
+	CC=${CC} DESTDIR=${DESTDIR} /bin/sh ${.CURDIR}/../kdump/mkioctls ${DESTDIR}/usr/include/sys/ioctl.h \
 	    ${DESTDIR}/usr/include/sys/ioctl_compat.h > ioctl.c
 
 ${DESTDIR}/usr/include/sys/ioctl.h ${DESTDIR}/usr/include/sys/ioctl_compat.h: .PRECIOUS