[Date Prev][Date Next][Thread Prev][Thread Next][Thread Index]
Re: [XaraXtreme-dev] includes, XARLIB and camtypes.h
- From: Alex Bligh <alex@xxxxxxxxxxx>
- Date: Fri, 09 Jun 2006 12:04:36 +0100
- Subject: Re: [XaraXtreme-dev] includes, XARLIB and camtypes.h
Gerry Iles wrote:
That's more like it. That updated a lot of the files in XarLib and now
there are build problems...
I should be able to sort them out fairly easily but they mostly seem to
be caused by include spaghetti (e.g. camresource.cpp needs ccfile.h so
that it will compile but that is currently included via camfiltr.h (and
possibly other things) that isn't part of XarLib. I should be able to
sort this out by explicitly including files like ccfile.h directly in
camtypes.h rather than relying on another header to pull them in.
Presumably then your removal script can be run again to remove ccfile.h
from all the other places it gets included.
I removed ALL instances of ccfile.h being included and indeed any
other headers indirectly included in camtypes (not just the
camtypes has a list of what was removed down the bottom (commented
out). Equally you can just look at PreComp/.deps/camtypes.h.gch.Po
To help this, is there an easy way (presumably using one of your
scripts) to tell how a particular header file is being included?
Scripts/gendeps.pl -e -i ccfile.h PreComp/.deps/camtypes.h.Po
will tell you what files ccfile.h is included by, whereas
Scripts/gendeps.pl -e -t ccfile.h PreComp/.deps/camtypes.h.Po
will tell you what files include ccfile.h
Note the above will restrict itself to files inside camtypes.h.
If you want all files in the project, replace the last parameter
There is some distinct horribleness here. For instance, coord.h
is somewhat circularly including camtypes.h. This should not be
necessary. By definition, when compiling any .cpp file, camtypes
is the first thing included, so it will always already have been
included. I have not yet tried spaghetti chopping inside
camtypes so you might want to have a go. My own view is no
files within camtypes should include camtypes.
BTW please get the latest fix to fixstr.xxx or things will randomly
segv, and the latest gendeps.