Changeset View
Changeset View
Standalone View
Standalone View
head/stand/defs.mk
Show First 20 Lines • Show All 183 Lines • ▼ Show 20 Lines | |||||
CLEANFILES+= teken_state.h | CLEANFILES+= teken_state.h | ||||
teken.c: teken_state.h | teken.c: teken_state.h | ||||
teken_state.h: ${SYSDIR}/teken/sequences | teken_state.h: ${SYSDIR}/teken/sequences | ||||
awk -f ${SYSDIR}/teken/gensequences \ | awk -f ${SYSDIR}/teken/gensequences \ | ||||
${SYSDIR}/teken/sequences > teken_state.h | ${SYSDIR}/teken/sequences > teken_state.h | ||||
.if !defined(NO_OBJ) | .if !defined(NO_OBJ) | ||||
_ILINKS=machine | _ILINKS=include/machine | ||||
.if ${MACHINE} != ${MACHINE_CPUARCH} && ${MACHINE} != "arm64" | .if ${MACHINE} != ${MACHINE_CPUARCH} && ${MACHINE} != "arm64" | ||||
_ILINKS+=${MACHINE_CPUARCH} | _ILINKS+=include/${MACHINE_CPUARCH} | ||||
.endif | .endif | ||||
.if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64" | .if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64" | ||||
_ILINKS+=x86 | _ILINKS+=include/x86 | ||||
.endif | .endif | ||||
CLEANFILES+=${_ILINKS} | CFLAGS+= -Iinclude | ||||
CLEANDIRS+= include | |||||
beforedepend: ${_ILINKS} | beforedepend: ${_ILINKS} | ||||
beforebuild: ${_ILINKS} | beforebuild: ${_ILINKS} | ||||
# Ensure that the links exist without depending on it when it exists which | # Ensure that the links exist without depending on it when it exists which | ||||
# causes all the modules to be rebuilt when the directory pointed to changes. | # causes all the modules to be rebuilt when the directory pointed to changes. | ||||
.for _link in ${_ILINKS} | .for _link in ${_ILINKS} | ||||
.if !exists(${.OBJDIR}/${_link}) | .if !exists(${.OBJDIR}/${_link}) | ||||
${OBJS}: ${_link} | ${OBJS}: ${_link} | ||||
.endif # _link exists | .endif # _link exists | ||||
.endfor | .endfor | ||||
.NOPATH: ${_ILINKS} | .NOPATH: ${_ILINKS} | ||||
${_ILINKS}: | ${_ILINKS}: .NOMETA | ||||
@case ${.TARGET} in \ | @case ${.TARGET:T} in \ | ||||
machine) \ | machine) \ | ||||
if [ ${DO32:U0} -eq 0 ]; then \ | if [ ${DO32:U0} -eq 0 ]; then \ | ||||
path=${SYSDIR}/${MACHINE}/include ; \ | path=${SYSDIR}/${MACHINE}/include ; \ | ||||
else \ | else \ | ||||
path=${SYSDIR}/${MACHINE:C/amd64/i386/}/include ; \ | path=${SYSDIR}/${MACHINE:C/amd64/i386/}/include ; \ | ||||
fi ;; \ | fi ;; \ | ||||
*) \ | *) \ | ||||
path=${SYSDIR}/${.TARGET:T}/include ;; \ | path=${SYSDIR}/${.TARGET:T}/include ;; \ | ||||
esac ; \ | esac ; \ | ||||
case ${.TARGET} in \ | |||||
*/*) mkdir -p ${.TARGET:H};; \ | |||||
esac ; \ | |||||
path=`(cd $$path && /bin/pwd)` ; \ | path=`(cd $$path && /bin/pwd)` ; \ | ||||
${ECHO} ${.TARGET:T} "->" $$path ; \ | ${ECHO} ${.TARGET} "->" $$path ; \ | ||||
ln -fhs $$path ${.TARGET:T} | ln -fhs $$path ${.TARGET} | ||||
.endif # !NO_OBJ | .endif # !NO_OBJ | ||||
.endif # __BOOT_DEFS_MK__ | .endif # __BOOT_DEFS_MK__ |