FreeBSD/Linux Kernel Cross Reference
sys/Makefile
1 #
2 # Mach Operating System
3 # Copyright (c) 1993-1989 Carnegie Mellon University
4 # All Rights Reserved.
5 #
6 # Permission to use, copy, modify and distribute this software and its
7 # documentation is hereby granted, provided that both the copyright
8 # notice and this permission notice appear in all copies of the
9 # software, derivative works or modified versions, and any portions
10 # thereof, and that both notices appear in supporting documentation.
11 #
12 # CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
13 # CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
14 # ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
15 #
16 # Carnegie Mellon requests users of this software to return to
17 #
18 # Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU
19 # School of Computer Science
20 # Carnegie Mellon University
21 # Pittsburgh PA 15213-3890
22 #
23 # any improvements or extensions that they make and grant Carnegie Mellon
24 # the rights to redistribute these changes.
25 #
26 #
27 # HISTORY
28 # $Log: Makefile,v $
29 # Revision 2.25 93/05/16 14:32:46 mrt
30 # Eliminate the include SUBDIR.
31 # [93/05/14 mrt]
32 #
33 # Revision 2.23.1.1 93/05/10 14:53:10 mrt
34 # Added ${MAKE_ARGS} to kernel_only make rule, at Daryl's
35 # suggestion. Makes possible commands like
36 #
37 # odemake MAKE_ARGS=`locore.o relink` kernel_only
38 # [93/04/08 mrt]
39 #
40 # Revision 2.23 93/03/26 17:54:35 mrt
41 # Added man to SUBDIRS.
42 #
43 #
44 # Revision 2.22 93/03/10 17:36:44 danner
45 # Expanded the kernel rule, so it would work in an empty shadow
46 # directory. Addded kernel_only target for building the kernel
47 # in an already populated area.
48 # [93/03/10 mrt]
49 #
50 # Revision 2.21 93/01/24 13:55:02 danner
51 # Created for Reno make
52 # [91/05/17 mrt]
53 #
54
55 EXPBIN_SUBDIRS = src
56 EXPLIB_SUBDIRS = src
57
58 CONFIG ?= ${KERNEL_${TARGET_MACHINE}_CONFIG:U${KERNEL_CONFIG:UDEFAULT}}
59
60 SUBDIRS = src conf ${CONFIG} man
61
62 .include <${RULES_MK}>
63
64 # default target is build_all and will traverse all of SUBDIRS
65
66 # kernel target does the minimum necessary to build a kernel (mach.boot)
67 # in an empty shadow directory
68
69 kernel:
70 @-if [ ! -d ../include ]; then mkdir ../include; fi
71 cd ../include && ${MAKE}
72 @-if [ ! -d ../bootstrap ]; then mkdir ../bootstrap; fi
73 cd ../bootstrap && ${MAKE}
74 @-if [ ! -d conf ]; then mkdir conf; fi
75 cd conf && ${MAKE}
76 cd ${CONFIG} && ${MAKE}
77
78 # kernel_only builds the kernel in a populated directory
79
80 kernel_only:
81 cd conf && ${MAKE}
82 cd ${CONFIG} && ${MAKE} ${MAKE_ARGS}
Cache object: 143e7b3c5e136ce8ddf53611d0d61811
|