g++ has a (mean) personaility

Did you ever get a message like “undefined reference to `__gxx_personality_v0′”? It means you are trying to link c++ code with a c linker, just change gcc with g++. But what is gxx_personality?

Basically, gxx_personality is a global pointer used for stack unwinding. You could make your code compile (assuming you don’t have other problems with vtables and such) by defining it as a NULL ptr, and everything should work until an exception is thrown.

Advertisements


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s