This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: GCC vs. `make' on Solaris
On Sun, May 13, 2001 at 07:10:48PM -0400, Andrew Pimlott wrote:
> On Fri, May 11, 2001 at 11:44:36PM -0300, Alexandre Oliva wrote:
> > But what we generally have is:
> >
> > foo.o: foo.c
> > gcc -c foo.c
> > foo.c: s-foo; @true
> > s-foo: bar
> > bar > tmp-foo
> > move-if-change tmp-foo foo.c
> > touch s-foo
> >
> > Even if foo.c is older than s-foo, GNU make is smart enough to figure
> > @true hasn't changed it, so it doesn't proceed to rebuilding foo.o.
>
> (While I'm on this thread ...)
>
> What is the point of the middle rule and s-foo?
It prevents foo.c from being regenerated every time you run make.
Some of the generators are slow, so this is important -
e.g. genattrtab takes almost a minute on my 500MHz Pentium III.
--
zw Actually, we have scientifically determined that Heisenberg did indeed
sleep exactly here. However, we have no idea whatsoever just how fast
asleep he was.
-- Dave Aronson