Subject: Re: make fails to execute ./fred because of a chdir()
To: David Laight <>
From: Simon J. Gerraty <>
List: tech-toolchain
Date: 12/13/2002 23:49:58
As Christos pointed out it is a feature.

>I had a horrid feeling that it was.

A simple workaround is to run:

MAKEOBJDIR=/dev/null make

MAKEOBJDIR in the environment overrides make's default of 'obj'.
I use this trick to allow doing a make clean in the src directory
even when object dirs exist.

>Wouldn't it have been better to require a .OBJDIR (or similar)
>command in the makefile itself to enable this 'feature'?

.OBJDIR was introduced in the last year or so, our make has behaved
this way for ~ever.