Subject: Re: tools/Makefile parallel make issue
To: Lubomir Sedlacik <>
From: David Laight <>
List: tech-toolchain
Date: 07/06/2006 19:57:56
On Thu, Jul 06, 2006 at 05:25:02PM +0200, Lubomir Sedlacik wrote:
> the failure was caused by a "cleandir" running in parallel within the
> same directory "dependall" was just spawned (running configure at the
> moment), in tools/compat.
> the problem seems to lie in src/tools/Makefile:
>   realall realdepend: .MAKE
>   .if "${PREVIOUSTOOLDIR}" != "${TOOLDIR}"
>           @echo "*** WARNING: TOOLDIR has moved?"
>           @echo "*** PREVIOUSTOOLDIR '${PREVIOUSTOOLDIR}'"
>           @echo "***     !=  TOOLDIR '${TOOLDIR}'"
>           @echo "*** Cleaning mis-matched tools"
>           rm -f PREVIOUSTOOLDIR
>           (cd ${.CURDIR} && ${MAKE} cleandir)
>   .endif

There is no way to get a single make command to execute commands that
delete files and commands that create the same ones.

The only solution I can see is moving the 'delete old tools' logic
(Or maybe getting it done as the makefle is parsed).

Usually we get away with the parallel cleandir and 'make obj'.


David Laight: