Home | History | Annotate | Line # | Download | only in host-mkdep
Makefile revision 1.12
      1 #	$NetBSD: Makefile,v 1.12 2012/12/02 12:44:06 apb Exp $
      2 
      3 HOSTPROG= 	host-mkdep
      4 HOSTPROGNAME=	${_TOOL_PREFIX}host-mkdep
      5 HOST_BINDIR=	${TOOLDIR}/bin
      6 
      7 NOMAN=	# defined
      8 SRCS=	# empty
      9 
     10 CLEANFILES+=	config.cache config.log config.status host-mkdep
     11 
     12 .include <bsd.hostprog.mk>
     13 
     14 # XXX: The configure script needs to use awk, but we can't pass
     15 # AWK=${TOOL_AWK:Q} in CONFIGURE_ENV, because TOOL_AWK is not yet
     16 # available at the time that host-mkdep is built.  The configure script
     17 # will try to find some other version of awk.
     18 #
     19 CONFIGURE_ENV=	CC=${HOST_CC:Q}
     20 
     21 realall: host-mkdep
     22 host-mkdep: configure host-mkdep.in
     23 	-rm -f $@
     24 	${CONFIGURE_ENV} \
     25 	    ${HOST_SH} ${.CURDIR}/configure --cache-file=config.cache
     26 	chmod +x $@
     27 
     28 # Use uninstalled copy of the install program
     29 INSTALL_OBJ!=	cd ${NETBSDSRCDIR}/tools/binstall && ${PRINTOBJDIR}
     30 INSTALL=	${INSTALL_OBJ}/xinstall
     31 
     32 # Install rule, copied from src/tools/Makefile.host.
     33 # We can't include Makefile.host because there is no HOST_SRCDIR
     34 # corresponding to host-mkdep.
     35 #
     36 realinstall: install.host
     37 install.host: ${HOST_BINDIR}/${HOSTPROGNAME}
     38 ${HOST_BINDIR}/${HOSTPROGNAME}:: ${HOSTPROG}
     39 	${_MKTARGET_INSTALL}
     40 	mkdir -p ${HOST_BINDIR}
     41 	${HOST_INSTALL_FILE} -m ${BINMODE} ${HOSTPROG}${HOSTEXEEXT} ${.TARGET}
     42 
     43 .if ${MKUPDATE} == "no"
     44 .PHONY:		${HOST_BINDIR}/${HOSTPROGNAME}
     45 .endif
     46 
     47 # Run by hand, then "configure" script committed:
     48 regen:
     49 	cd ${.CURDIR} && ${TOOLDIR}/bin/${_TOOL_PREFIX}autoconf
     50