From: rillian <ri...@te...> - 2002-02-03 21:44:28
|
On 01/31/2002 at 15:58:51 Andrew Evans wrote: > The preprocessor macro __GNUC__ contains the major version number of > the compiler. __GNUC_MINOR__ contains the minor version number of the > compiler, as you'd expect. So you can replace '#ifdef GCC_VER_3' with > '#if defined(__GNUC__) && (__GNUC__ >= 3)', I think. Unfortunately this isn't sufficient. The default compiler on Debian woody calls itself 2.95.4. So this check isn't sufficient. However, building current cvs with -DGCC_VER_3 does repair the link problems I was seeing 'out of the box' with 2.95.4. Just so we're all on the same page, this particular trouble looks like: make[1]: Entering directory `/home/giles/projects/ghostscript/omni/XMLParser' c++ -o parser MyErrorHandler.o OmniDomParser.o Main.o -L .. -lomni -lxml -L/usr/lib -rdynamic -lgmodule -lglib -ldl ../libomni.so: undefined reference to `getEnumeration__Q312OmniPDCProxy38getCurrentResolution__12OmniPDCProxy.0_22OmniPDCProxyResolution.987' [...and many similar undefined references] Building with DEBUG=1 also remedied this. The (__GNUC__ > 3) check does work with gcc-3.0, but there appear to additional source gotchas: g++-3.0 -Wall -fPIC -rdynamic -O3 -DRETAIL=1 -I . -I hppcl3 -I/usr/include/glib-1.2 -I/usr/lib/glib/include -c DeviceBlitter.cpp In file included from DeviceBlitter.cpp:19: Device.hpp:141: type specifier omitted for parameter Device.hpp:141: parse error before `)' token make: *** [DeviceBlitter.o] Error 1 I hope we can get this cleared up and building more portably soon. Cheers, -ralph |