tech-toolchain archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: make: creating a file's parent directory
On Thu, Jul 16, 2015 at 05:27:39PM +0000, David Holland wrote:
> I don't think there are any particularly good ways - you can do
> something like
>
> dir:
> mkdir dir
>
> .dir.stamp:
> @[ -d dir ] || $(MAKE) dir
>
> dir/file: .dir.stamp
> ... >${.TARGET}
Er, obviously you need "touch .dir.stamp" at the end of the .dir.stamp
rule.
--
David A. Holland
dholland%netbsd.org@localhost
Home |
Main Index |
Thread Index |
Old Index