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

[XaraXtreme-dev] includes, XARLIB and camtypes.h

[Gerry especially]

I have an automatic mechanism of stripping include files that are
already included (directly or indirectly) in camtypes.h out from
files that are not themselves part of camtypes. It gives a
build speed improvement for a complete rebuild of between
10% and 20% (down from approx 2 mins 30 to 2 mins 05). I suspect
the improvement will be greater the less powerful the machine

It removes 3,926 unnecessary instances of #include.

My problem is with XARLIB. Currently the contents of camtypes.h
depend on whether XARLIB is defined. If I remove ALL the files,
then conceivably those files could be used by a cpp in XARLIB
and the #includes will need to be added manually
However, I can't blindly stick in the includes back into
camtypes.h when XARLIB is defined as they might not even

Would a reasonably approach be for me to remove the
"#ifndef XARLIB" in camtypes.h, and for any headers that
you don't want (Gerry) because it doesn't compile, #ifndef
the whole header out inside the header itself?

On a separate note, I have restored some disabled bits
to camtypes.h which should speed things up, and added
a few more files that were included by over a hundred
object files. This should optimize speed for those
compiling with pch's (sorry Mr Build Server and anyone
on gcc<3.4).

I've made substantial progress disentangling include spaghetti
but there's not a great deal more I can do without serious
surgery (i.e. actually changing the to use pointers rather
than included members, etc.)