Makefile revision 180428
150477Speter# $FreeBSD: head/sys/Makefile 180428 2008-07-10 16:03:24Z obrien $
21598Srgrimes
3156813Sru.include <bsd.own.mk>
4156813Sru
558284Speter# The boot loader
6156813Sru.if ${MK_BOOT} != "no"
7116865SpeterSUBDIR=	boot
8129269Scognet.endif
91598Srgrimes
10143145Sgrog# Directories to include in cscope name file and TAGS.
11179174SobrienCSCOPEDIRS=	boot bsm cam compat conf contrib crypto ddb dev fs gdb geom \
12179315Sbz		gnu isa kern libkern modules net net80211 netatalk \
13171245Sbz		netgraph netinet netinet6 netipsec netipx netnatm netncp \
14175593Smaxim		netsmb nfs nfs4client nfsclient nfsserver opencrypto pccard \
15180428Sobrien		pci rpc security sys ufs vm ${CSCOPE_ARCHDIR}
16180428Sobrien.if defined(ALL_ARCH)
17180428SobrienCSCOPE_ARCHDIR ?= amd64 arm i386 ia64 mips powerpc sparc64
18180428Sobrien.else
19180428SobrienCSCOPE_ARCHDIR ?= ${MACHINE}
20180428Sobrien.endif
21143145Sgrog
22124610Sru# Loadable kernel modules
23143145Sgrog
2461744Sobrien.if defined(MODULES_WITH_WORLD)
2561744SobrienSUBDIR+=modules
2661744Sobrien.endif
2761744Sobrien
2827356SjkhHTAGSFLAGS+= -at `awk -F= '/^RELEASE *=/{release=$2}; END {print "FreeBSD", release, "kernel"}' < conf/newvers.sh`
2927356Sjkh
30171245Sbz# You need the devel/cscope port for this.
31179174Sobriencscope: cscope.out
32179174Sobriencscope.out: ${.CURDIR}/cscope.files
33179174Sobrien	cd ${.CURDIR}; cscope -k -buq -p4
34143145Sgrog
35179174Sobrien${.CURDIR}/cscope.files: .PHONY
36179174Sobrien	cd ${.CURDIR}; \
37179174Sobrien		find ${CSCOPEDIRS} -name "*.[chSs]" -a -type f > ${.TARGET}
38143145Sgrog
39179174Sobriencscope-clean:
40179174Sobrien	rm -f cscope.files cscope.out cscope.in.out cscope.po.out
41179174Sobrien
42171245Sbz# You need the devel/global and one of editor/emacs* ports for that.
43179174SobrienTAGS ${.CURDIR}/TAGS: ${.CURDIR}/cscope.files
44143145Sgrog	rm -f ${.CURDIR}/TAGS
45179174Sobrien	cd ${.CURDIR}; xargs etags -a < ${.CURDIR}/cscope.files
46143145Sgrog
471598Srgrimes.include <bsd.subdir.mk>
48