Tristan,
Thanks.
This accomplishes some of what we need. If "my_dir" exists, make
treats the
"my_dir"/Makfile dependency as an actual file within a subdirectory, and a
"touch" of
/my_dir/Makfile will force a recompile.
If my_dir doesn't exist "my_dir/Makefile" is treated as a target.
Since there
no rule exists for that target, make crashes.
We would like make to stop if there are no other targets to build, or
go to the next target
if running "make.all"
Tristan Van
Berkom To: Jimmy DeWitt/Austin/[EMAIL
PROTECTED]
<[EMAIL PROTECTED] cc: [EMAIL PROTECTED]
.com> Subject: Re: How do I check if a
directory exists?
12/08/2003 11:35
AM
Jimmy DeWitt wrote:
> Hi,
> I have a make question:
>
> How do I test if a directory exists with make?
>
>
> I would like to have a Makefile that checks if a specific directory is
> there, if it
> is I would like to cd to it and build .
>
> if foo
> cd foo
> make -f my_makefile
>
>
> Is there a way to do this without scripts?
Would this suite your purpose ?
target: my_dir/Makefile
$(MAKE) -C my_dir
Cheers,
-Tristan
_______________________________________________
Help-make mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/help-make
- How do I check if a directory exists? Jimmy DeWitt
- Re: How do I check if a directory exists? Tristan Van Berkom
- Re: How do I check if a directory exists? Eric Hanchrow
- Jimmy DeWitt
