views:

54

answers:

2

When I try to use boost on an old Linux system, I get the message:

Compiler not configured - please reconfigure

The version of my gcc is:

gcc version 2.9-gnupro-99r1

And in boost's gcc.hpp file I see:

// versions check:
// we don't know gcc prior to version 2.90:
#if (__GNUC__ == 2) && (__GNUC_MINOR__ < 90)
#  error "Compiler not configured - please reconfigure"
#endif

So, are gcc 2.9 and 2.90 actually the same thing? If yes - can I just update the gcc.hpp? And if not, how can I still use boost?


EDIT:

I actually tried to change (__GNUC_MINOR__ < 90) to (__GNUC_MINOR__ < 9). Seems like 2.9 and 2.90 are not the same because now I get compilation errors.

Seems like the errors are because this compiler doesn't support the \ (line extension) characters in the preprocessor macros. These line breaks are used by boost in many places.

+2  A: 

All C and C++ compilers have supported the \ in macros since the year dot, so that is not the problem. I think it unlikely that Boost will support 2.9x compilers (but who knows?) - why not simply upgrade the compiler? GCC is now on version 4.5, so yours is ridiculously outdated.

You might also want to look at this page, which documents Boost's compiler support.

anon
I can't upgrade the compiler in this case, so will be looking for another solution..
Igor Oks
+2  A: 

If you can't upgrade the compiler, downgrade the sources. Not really very sensible advice, but still, it might work.

Old Boost releases are found here: http://sourceforge.net/projects/boost/files/

Good luck!

PS: if it's the line breaks that are killing you, maybe you can try to remove them (if there aren't too many)

rubenvb