[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: precompiled header suggestion
From: |
Tom Tromey |
Subject: |
Re: precompiled header suggestion |
Date: |
10 Oct 2003 18:52:38 -0600 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 |
>>>>> "adl" == Alexandre Duret-Lutz <address@hidden> writes:
adl> This sounds tricky. Adding such a file as a dependency of each .o file
adl> means that _all_ of them will be updated whenever the .ghc changes.
Good point. There are other possible approaches, though.
For instance, for a given program, we could generate:
am--program: $(program_BUILT_SOURCES)
$(MAKE) program
... which is sort of like the BUILT_SOURCES implementation, but more
targeted.
That's sort of backward, since "make program" will no longer work as
expected. But you get the idea...
I suppose this is sort of secondary, and the main thing is just to
have some automation for building the .gch file at all.
adl> Putting the .ghc in BUILT_SOURCES automatically will not work if
adl> the .ghc includes another BUILT_SOURCES indirectly (direct
adl> inclusion is ok because we can issue the dependency ourself).
adl> Maybe we can live with such a limitation?
Yeah, there could be some problems here. But the user can always add
an explicit dependency (just adding the .h to the gch file's _SOURCES
would suffice).
adl> Also I presume some libraries will also want to install such
adl> files? Can they be installed? (Is this what install-pch is
adl> about in your libstdc++ quote?) If so, such installation also
adl> needs to be conditional.
Honestly, I don't know too much about this. I'd suggest we leave
open the possibility that they can be installed, though.
adl> Maybe it would be simpler to introduce a new primary
Yeah. Another idea would be to recognize `*.gch' automatically in a
_SOURCES variable corresponding to a program or library.
Tom