[EMAIL PROTECTED] wrote:
> 
> On Wed, 27 Aug 2003 07:37:46 -0400, Noel Yap <[EMAIL PROTECTED]> said:
> 
> >> I would like a way to list all dependencies and subdependencies of
> >> a given target to avoid the recursive shell function hackism I
> >> currently have to do when using "make -pnq".
> 
> > IMHO, don't use recursive make:
> > http://www.tip.net.au/~millerp/rmch/recu-make-cons-harm.html.
> 
>         I get a file not found error at thet URI, but the recursion is
>  not the major point here. Indeed, the recursion here may not even
>  refer to using make recursively -- the point here is to discover all the
>  targets that would be looked at when I run make. So, if the target of
>  interest is "install", which depends on "build", which depends on
>  my-program-name, which depends on main.o, which depends on main.c,
>  which depends on /usr/include/stdio.h; I want to have all these
>  dependencies listeed -- and I am justusing a simple Makefile.

Sorry for not checking the URL.  If you're still interested in the paper, googling for 
"recursive make harmful" turns up many links.

> > If I'm misunderstanding the problem, can you provide more details,
> > please?
> 
>         All right. Suppose I want to create a wrapper around make that
>  would call make automatically when one of the files that a make
>  target depends on changes. How do I discover what those files are?

I don't understand, make already does this.  Why not just call make?

>         Obviously, make knows, since when it is actually run it goes
>  through, and tests files/targets to see if they need rebuilding. What
>  is requested is a mode in which each target is assumed to be in need
>  of rebuilding, but, instead of taking any action, all that is done is
>  to print the target's name on stdout.
> 
>         I hope this is clearer.

Yes, much clearer.  Have you tried "make -n"?

HTH,
Noel


_______________________________________________
Bug-make mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/bug-make

Reply via email to