From: Dave Korn <dave.korn.cygwin@googlemail.com>
To: Jie Zhang <jie.zhang@analog.com>
Cc: Ralf.Wildenhues@gmx.de, binutils@sourceware.org
Subject: Re: Parallel build error for Blackfin target
Date: Tue, 01 Sep 2009 07:11:00 -0000 [thread overview]
Message-ID: <4A9CCC56.9090008@gmail.com> (raw)
In-Reply-To: <4A9CC410.7060301@analog.com>
Jie Zhang wrote:
> Previously
>
> bfin-lex.o: bfin-lex.c bfin-parse.h $(srcdir)/config/bfin-defs.h
> $(COMPILE) -c $< $(NO_WERROR)
>
> Now
>
> bfin-lex.o: bfin-lex.c
> if am__fastdepCC
> $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@
> bfin-lex.c $(NO_WERROR)
> mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
> else
> if AMDEP
> source='bfin-lex.c' object='$@' libtool=no @AMDEPBACKSLASH@
> DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
> endif
> $(COMPILE) -c bfin-lex.c $(NO_WERROR)
> endif
>
> Should I add back "bfin-parse.h $(srcdir)/config/bfin-defs.h" as the
> dependency of bfin-lex.o?
Perhaps $(srcdir)/config/bfin-defs.h should be added as a preqrequisite of
bfin-parse.c (and hence implicitly of bfin-parse.h).
Really the whole thing needs some kind of sentinel or stamp wrapped around
it(*); what we've got here is the typical "make doesn't understand when a
single rule updates more than one target at once" situation. Running the rule
for bfin-parse.c actually also creates bfin-parse.h, which is what
necessitates the not-really-true-actually dependency of bfin-parse.h on
bfin-parse.c and the corresponding "@true" build rule. See also Paul D.
Smith's Rules of Makefiles; this violates #2.
cheers,
DaveK
--
(*) - or perhaps to be converted to a multiple-output pattern rule, the other
way to resolve this kind of situation and the one place where make does
understand it might generate multiple outputs from a single rule.
next prev parent reply other threads:[~2009-09-01 7:11 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-09-01 6:50 Jie Zhang
2009-09-01 7:11 ` Dave Korn [this message]
2009-09-01 8:29 ` Jie Zhang
2009-09-01 8:41 ` Jie Zhang
2009-09-01 9:58 ` [PATCH] Fix parallel build error for Blackfin target (was Re: Parallel build error for Blackfin target) Jie Zhang
2009-09-01 21:14 ` Ralf Wildenhues
2009-09-02 6:24 ` Jie Zhang
2009-09-01 21:00 ` Parallel build error for Blackfin target Ralf Wildenhues
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4A9CCC56.9090008@gmail.com \
--to=dave.korn.cygwin@googlemail.com \
--cc=Ralf.Wildenhues@gmx.de \
--cc=binutils@sourceware.org \
--cc=jie.zhang@analog.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).