> How about adding
>
> #ifdef _USE_PCH
> #include <pch.h>
> #endif

I think that you could put that in the scons generated "common/config.h"
and stay in peace with Lars and the LyX source code ;-)

That will not work since msvc will scan the source code itself, not
into config.h.

> and change --include=pch.h  to -D_USE_PCH?

Quite frankly I don't think the use of PCH is a panacea. I think it is
just an excuse for badly written code. By using forward declaration
(class foo) in header you reduce considerably the compile time already
and I like to specify only the header I need in the .cpp file.

I am not quite enthusiastic about pch since my benchmarks show less
than 10% of performance improvement (autotools). However, I had the
feeling that to compete with autotools, this is a must have feature
for scons (among other things like distcheck).

Bo

Reply via email to