[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: make always builds, part 2
From: |
David Boyce |
Subject: |
Re: make always builds, part 2 |
Date: |
Tue, 15 Nov 2011 08:22:46 -0500 |
On Tue, Nov 15, 2011 at 7:53 AM, Paul Smith <address@hidden> wrote:
> __dummy := $(shell mkdir $(OBJDIRECTORY))
Generally best here (again, assuming POSIX) to use mkdir -p which does
not fail if the directory already exists.
> Second, you can create it as a side-effect of every target that needs it
> (in the script for that target).
This is not parallel-safe because two recipes building unrelated
targets in the same directory might run mkdir at the same time.
> And third, you can use order-only prerequisites:
>
> %.d : %.cpp | $(OBJDIRECTORY)
> ...
This, IMHO, is the "right" way.
-David Boyce
- make always builds, part 2, Edgar, 2011/11/15
- RE: make always builds, part 2, Warlich, Christof, 2011/11/15
- Re: make always builds, part 2, Paul Smith, 2011/11/15
- Re: make always builds, part 2,
David Boyce <=
- Re: make always builds, part 2, Eli Zaretskii, 2011/11/15