1 # $NetBSD: bsd.dep.mk,v 1.68 2008/10/25 22:27:36 apb Exp $
5 realdepend
: beforedepend .depend afterdepend
6 .ORDER
: beforedepend .depend afterdepend
8 beforedepend .depend afterdepend
: # ensure existence
15 # some of the rules involve .h sources, so remove them from mkdep line
18 __acpp_flags
= ${_TRADITIONAL_CPP}
20 __DPSRCS.
all= ${SRCS
:C
/\.
(c|m|s|S|C|
cc|
cpp|
cxx)$/.d
/} \
21 ${DPSRCS
:C
/\.
(c|m|s|S|C|
cc|
cpp|
cxx)$/.d
/}
22 __DPSRCS.d
= ${__DPSRCS.
all:O
:u
:M
*.d
}
23 __DPSRCS.notd
= ${__DPSRCS.
all:O
:u
:N
*.d
}
25 .NOPATH
: .depend
${__DPSRCS.d
}
27 .if
!empty
(__DPSRCS.d
) # {
28 ${__DPSRCS.d
}: ${__DPSRCS.notd
} ${DPSRCS}
31 .depend
: ${__DPSRCS.d
}
34 ${MKDEP} -d
-f
${.TARGET
} -s
${MKDEP_SUFFIXES
:Q
} ${__DPSRCS.d
}
36 .SUFFIXES
: .d .s .S .c .C .
cc .
cpp .
cxx .m
40 ${MKDEP} -f
${.TARGET
} -- ${MKDEPFLAGS} \
41 ${CFLAGS
:C
/-([IDU
])[ ]*/-\
1/Wg
:M-
[IDU
]*} \
42 ${CPPFLAGS} ${CPPFLAGS.
${.IMPSRC
:T
}} ${.IMPSRC
}
46 ${MKDEP} -f
${.TARGET
} -- ${MKDEPFLAGS} \
47 ${OBJCFLAGS
:C
/-([IDU
])[ ]*/-\
1/Wg
:M-
[IDU
]*} \
48 ${CPPFLAGS} ${CPPFLAGS.
${.IMPSRC
:T
}} ${.IMPSRC
}
52 ${MKDEP} -f
${.TARGET
} -- ${MKDEPFLAGS} \
53 ${AFLAGS
:C
/-([IDU
])[ ]*/-\
1/Wg
:M-
[IDU
]*} \
54 ${CPPFLAGS} ${CPPFLAGS.
${.IMPSRC
:T
}} ${__acpp_flags} ${.IMPSRC
}
56 .C.d .
cc.d .
cpp.d .
cxx.d
:
58 ${MKDEP} -f
${.TARGET
} -- ${MKDEPFLAGS} \
59 ${CXXFLAGS
:C
/-([IDU
])[ ]*/-\
1/Wg
:M-
[IDU
]*} \
60 ${DESTDIR
:D-nostdinc
++ ${CPPFLAG_ISYSTEMXX} \
61 ${DESTDIR}/usr
/include/g
++} \
62 ${CPPFLAGS} ${CPPFLAGS.
${.IMPSRC
:T
}} ${.IMPSRC
}
64 .
endif # defined(SRCS) # }
69 rm -f .depend
${__DPSRCS.d
} ${.CURDIR
}/tags ${CLEANDEPEND}
76 -cd
${.CURDIR
}; ctags
-f
/dev
/stdout
${.ALLSRC
:N
*.h
} | \
77 ${TOOL_SED} "s;\${.CURDIR}/;;" > tags