diff --git a/sys/conf/Makefile.i386 b/sys/conf/Makefile.i386 index 4bcd03fa7210..14f830830088 100644 --- a/sys/conf/Makefile.i386 +++ b/sys/conf/Makefile.i386 @@ -1,6 +1,6 @@ # Copyright 1990 W. Jolitz # from: @(#)Makefile.i386 7.1 5/10/91 -# $Id: Makefile.i386,v 1.60 1995/03/28 08:02:37 bde Exp $ +# $Id: Makefile.i386,v 1.61 1995/04/03 01:13:50 nate Exp $ # # Makefile for FreeBSD # @@ -36,7 +36,13 @@ CWARNFLAGS?=-W -Wreturn-type -Wcomment -Wredundant-decls -Wimplicit # COPTFLAGS?=-O # Not ready for -I- yet. #include "foo.h" where foo.h is in the srcdir fails. -INCLUDES= -nostdinc -I. -I$S -I$S/sys -I$S/../include -I/usr/include +INCLUDES= -nostdinc -I. -I$S -I$S/sys +# This hack is to allow kernel compiles to succeed on machines w/out srcdist +.if exists($S/../include) +INCLUDES+= -I$S/../include +.else +INCLUDES+= -I/usr/include +.endif COPTS= ${INCLUDES} ${IDENT} -DKERNEL -Di386 -DLOAD_ADDRESS=0x${LOAD_ADDRESS} ASFLAGS= CFLAGS= ${COPTFLAGS} ${CWARNFLAGS} ${DEBUG} ${COPTS} diff --git a/sys/conf/Makefile.powerpc b/sys/conf/Makefile.powerpc index 4bcd03fa7210..14f830830088 100644 --- a/sys/conf/Makefile.powerpc +++ b/sys/conf/Makefile.powerpc @@ -1,6 +1,6 @@ # Copyright 1990 W. Jolitz # from: @(#)Makefile.i386 7.1 5/10/91 -# $Id: Makefile.i386,v 1.60 1995/03/28 08:02:37 bde Exp $ +# $Id: Makefile.i386,v 1.61 1995/04/03 01:13:50 nate Exp $ # # Makefile for FreeBSD # @@ -36,7 +36,13 @@ CWARNFLAGS?=-W -Wreturn-type -Wcomment -Wredundant-decls -Wimplicit # COPTFLAGS?=-O # Not ready for -I- yet. #include "foo.h" where foo.h is in the srcdir fails. -INCLUDES= -nostdinc -I. -I$S -I$S/sys -I$S/../include -I/usr/include +INCLUDES= -nostdinc -I. -I$S -I$S/sys +# This hack is to allow kernel compiles to succeed on machines w/out srcdist +.if exists($S/../include) +INCLUDES+= -I$S/../include +.else +INCLUDES+= -I/usr/include +.endif COPTS= ${INCLUDES} ${IDENT} -DKERNEL -Di386 -DLOAD_ADDRESS=0x${LOAD_ADDRESS} ASFLAGS= CFLAGS= ${COPTFLAGS} ${CWARNFLAGS} ${DEBUG} ${COPTS} diff --git a/sys/i386/conf/Makefile.i386 b/sys/i386/conf/Makefile.i386 index 4bcd03fa7210..14f830830088 100644 --- a/sys/i386/conf/Makefile.i386 +++ b/sys/i386/conf/Makefile.i386 @@ -1,6 +1,6 @@ # Copyright 1990 W. Jolitz # from: @(#)Makefile.i386 7.1 5/10/91 -# $Id: Makefile.i386,v 1.60 1995/03/28 08:02:37 bde Exp $ +# $Id: Makefile.i386,v 1.61 1995/04/03 01:13:50 nate Exp $ # # Makefile for FreeBSD # @@ -36,7 +36,13 @@ CWARNFLAGS?=-W -Wreturn-type -Wcomment -Wredundant-decls -Wimplicit # COPTFLAGS?=-O # Not ready for -I- yet. #include "foo.h" where foo.h is in the srcdir fails. -INCLUDES= -nostdinc -I. -I$S -I$S/sys -I$S/../include -I/usr/include +INCLUDES= -nostdinc -I. -I$S -I$S/sys +# This hack is to allow kernel compiles to succeed on machines w/out srcdist +.if exists($S/../include) +INCLUDES+= -I$S/../include +.else +INCLUDES+= -I/usr/include +.endif COPTS= ${INCLUDES} ${IDENT} -DKERNEL -Di386 -DLOAD_ADDRESS=0x${LOAD_ADDRESS} ASFLAGS= CFLAGS= ${COPTFLAGS} ${CWARNFLAGS} ${DEBUG} ${COPTS}