Home | History | Annotate | Line # | Download | only in sys
      1 #	$NetBSD: Makefile,v 1.5 2024/04/01 02:18:30 christos Exp $
      2 
      3 .include <bsd.hostinit.mk>
      4 
      5 SRCDIR=	${.CURDIR}/../../../../external/bsd/elftoolchain/dist/common/sys
      6 
      7 .PATH:	${SRCDIR}
      8 
      9 INCS=		elfdefinitions.h
     10 HOST_INCSDIR=	${TOOLDIR}/include/sys
     11 
     12 # Too early for ${TOOL_M4}
     13 elfdefinitions.h:	elfdefinitions.m4 elfconstants.m4
     14 	${_MKTARGET_CREATE}
     15 	${TOOL_M4} -I${SRCDIR} -D SRCDIR=${SRCDIR} ${M4FLAGS} \
     16 		elfdefinitions.m4 > ${.TARGET}
     17 
     18 .PHONY:	all clean clobber depend
     19 
     20 install: .PHONY ${HOST_INCSDIR} .WAIT includes
     21 
     22 ${HOST_INCSDIR}:
     23 	${_MKTARGET_INSTALL}
     24 	${HOST_INSTALL_DIR} ${HOST_INCSDIR}
     25 
     26 .for _f in ${INCS}
     27 HOST_INCINSTFILES+= ${HOST_INCSDIR}/${_f}
     28 ${HOST_INCSDIR}/${_f}: ${_f}
     29 	${_MKTARGET_INSTALL}
     30 	${HOST_INSTALL_FILE} -m ${NONBINMODE} ${.ALLSRC} ${.TARGET}
     31 .endfor
     32 
     33 includes: .PHONY ${HOST_INCSDIR} .WAIT ${HOST_INCINSTFILES}
     34 
     35 all dependall depend:	${INCS}
     36 
     37 clean clobber:
     38 	rm -f ${INCS}
     39 
     40 cleandepend:
     41 	rm -f ${.OBJDIR}/.depend
     42 
     43 .include <bsd.obj.mk>
     44