[GCC-XML] ACE and gccxml?
Brad King
brad.king at kitware.com
Tue Feb 1 16:01:06 EST 2005
Timothy Paul Johnson wrote:
> I’m having trouble using gccxml on a project that has recently started
> to use the ACE multi-platform library (from
> http:/www.cs.wustl.edu/~schmidt/ACE.html)
> I have one header file (generated.h) with one line:
> #include "ace\OS.h"
> And I run the following command:
> "\Program Files\GccXml\bin\gccxml.exe" --gccxml-compiler msvc7 -D _MT -I
> "c:\Program Files\ACE" -fxml=generated.xml Generated.h
Okay, it looks like most of the problems are caused by the fact that the
GCC internal to GCC-XML is defining __STDC__ and __MINGW32__, but MSVC
does not define them. I've updated the simulation flags to use
"-U__STDC__ -U__MINGW32__" to remove these flags. This takes care of
most of the errors. There was one problem in VS's process.h that I had
to fix and add to the GCC-XML header patching. Both of these changes
are now in CVS.
The last error is in ace/OS_NS_time.inl. You'll have to patch this
header on these lines:
// Linux won't compile unless we explicitly use a namespace here.
#if defined (__GNUG__)
namespace ACE_OS {
ACE_INLINE long
timezone (void)
{
return ::ace_timezone ();
}
} /* namespace ACE_OS */
#else
ACE_INLINE long
ACE_OS::timezone (void)
{
return ::ace_timezone ();
}
#endif /* linux */
This works around a bug in GCC's parser. We need to make sure this
work-around is still used. Change the first line to
#if defined (__GNUG__) || defined (__GCCXML__)
-Brad
More information about the gccxml
mailing list