Ethereal-dev: Re: [ethereal-dev] Targets dependent on proto.h

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Gilbert Ramirez <gram@xxxxxxxxxx>
Date: Wed, 12 Apr 2000 13:13:44 -0500
On Wed, Apr 12, 2000 at 12:34:10PM -0500, Ben Fowler wrote:
> 
> 
> At 12:28 PM 4/12/00, Guy Harris wrote:
> >[ ...]
> >
> >OK, so you're working with a source distribution rather than from a
> >source tree checked out from CVS, as I am.
> 
> Checked out source, honest.
> 
> If you could give me a clue as to which file is faulty (differs between
> distribution & CVS), I will fix it.
> 
> Ben.

If you're using checked-out source, then automake should have
created an appopriate Makefile.in that has this clause in it:

%.o: %.c
        @echo '$(COMPILE) -c $<'; \
        $(COMPILE) -Wp,-MD,.deps/$(*F).pp -c $<
        @-cp .deps/$(*F).pp .deps/$(*F).P; \
        tr ' ' '\012' < .deps/$(*F).pp \
          | sed -e 's/^\\$$//' -e '/^$$/ d' -e '/:$$/ d' -e 's/$$/ :/' \
            >> .deps/$(*F).P; \
        rm .deps/$(*F).pp

Notice the -Wp,-MD option to $(COMPILE). 'automake' is run when
initializing your checked-out source via './autogen.sh'

When packing the source for a distribution via 'make dist', this
auto-generation of dependencies is removed, and the dependencies themselves
are put into Makefile.in.

--gilbert