[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: "Deleted header file" problem: aclocal.m4 deps

From: Ralf Wildenhues
Subject: Re: "Deleted header file" problem: aclocal.m4 deps
Date: Tue, 17 Jul 2007 00:23:31 +0200
User-agent: Mutt/1.5.13 (2006-08-11)

* Alexandre Duret-Lutz wrote on Mon, Jul 16, 2007 at 10:45:52PM CEST:
> >>> "RW" == Ralf Wildenhues <address@hidden> writes:
>  RW> +cat >> <<EOF
>  RW> +FOO
>  RW> +EOF
>  RW> +cat >foo.m4 <<EOF
>  RW> +AC_DEFUN([FOO], [:])
>  RW> +EOF
>  RW> +: >
>  RW> +$ACLOCAL -I .
>  RW> +./configure
>  RW> +$MAKE
>  RW> +sed '/FOO/d' < > t
>  RW> +mv -f t
>  RW> +rm -f foo.m4
>  RW> +$MAKE
> I'm not convinced by this test: what proof do I have that this
> last $MAKE is doing The Right Thing?

Hmm.  You may not have.

> How about something along the lines of (not tested) :
> cat >> <<EOF
> cat >foo.m4 <<EOF

Do you mean


> cat >bar.m4 <<EOF

I'm sorry but I'm unable to infer what you meant here,
or what you're trying to test by use of bar.m4.

> echo 'ACLOCAL_AMFLAGS = -I .'  >
> ./configure
> grep GREPFOO Makefile
> grep GREPBAR Makefile || exit 1

`&&' instead of `||'?

> sed '/FOO/d' < > t
> mv -f t
> rm -f foo.m4
> grep GREPFOO Makefile || exit 1


> grep GREPBAR Makefile

I can redo the patch if you like, given above.

>  RW> I can see two possible counterarguments, which is why I would be
>  RW> grateful if Alexandre could comment:
> These don't look like problems to me.

OK good.

> On a slightly different topic, but related to these
> "dependency-less" targets, I've been wondering several times
> whether it would be correct to add such a rule for the
> .deps/*.P* files.  I'm thinking of something like
> ./$(DEPDIR)/foo.Plo ./$(DEPDIR)/bar.Plo ./$(DEPDIR)/baz.Plo ...:
>         @echo '# dummy' > $@
> Although I'm not sure when this happens, occasionally some
> .deps/*.P* files get lost, make complains, and it's not obvious
> to users they have to run ./config.status to get them back.  

Well, wouldn't it be better to find out the cause of them being lost?
Of course, some users like to 'rm -rf' subtrees, which is a probable
cause.  Non-recursive make makes cleaning of subtrees a bit harder.

> GNU make will rebuild a missing `include'd file for which there
> exist a rule, but BSD make will not.  That means the above rule
> would just be an help to users of GNU make, not a replacement

So that's not really a good help then, but will cause action to differ
even more.

> (I which there was
> a way to get rid of AM_OUTPUT_DEPENDENCY_COMMANDS!)

I should point out that I've been working on this macro, on and off.
Without a final result, but with some crazy ideas at least:

> Someone once suggested using "-include" instead of "include",
> when available.  I would see that as complementary.

Was it not that there was no portable "-include" among 'make'
implementations?  (I don't remember well, but I do remember that
there was a mildly compelling reason against it.)


reply via email to

[Prev in Thread] Current Thread [Next in Thread]