tech-toolchain archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: make rule of multiple file generation (was Re: CVS commit: src/share/mk)
On Mon, Dec 14, 2009 at 12:38:06PM +0900, enami tsugutomo wrote:
> > So this is fixed with an additional dependency to force serialization,
> > or by fixing the script not to re-use the same temp filenames:
> >
> > nodes.h: nodes.c
> > nodes.c nodes.h: mknodes.sh nodetypes nodes.c.pat
> > ${_MKTARGET_CREATE}
> > ${SCRIPT_ENV} ${HOST_SH} ${.ALLSRC:S/^nodes.c$//} ${.OBJDIR}
> > [ -f nodes.h ]
>
> This ugly :S/^nodes.c$// modifier can be avoided by using .ORDER to
> force serialization, can't it?
I've never known ".ORDER". This works for me:
.ORDER: nodes.h nodes.c
nodes.c nodes.h: mknodes.sh nodetypes nodes.c.pat
${_MKTARGET_CREATE}
${SCRIPT_ENV} ${HOST_SH} ${.ALLSRC} ${.OBJDIR}
Masao
--
Masao Uebayashi / Tombi Inc. / Tel: +81-90-9141-4635
Home |
Main Index |
Thread Index |
Old Index