diff --git a/panda/src/express/nodeReferenceCount.I b/panda/src/express/nodeReferenceCount.I index d87bc982d8..66a8be1cea 100644 --- a/panda/src/express/nodeReferenceCount.I +++ b/panda/src/express/nodeReferenceCount.I @@ -213,7 +213,7 @@ NodeRefCountObj(const Base ©) : Base(copy) { template void NodeRefCountObj:: init_type() { -#if defined(HAVE_RTTI) && !defined(__EDG__) +#if defined(HAVE_RTTI) && !defined(__EDG__) && (!defined(__GNUC__) || defined(__GXX_RTTI)) // If we have RTTI, we can determine the name of the base type. std::string base_name = typeid(Base).name(); #else diff --git a/panda/src/express/referenceCount.I b/panda/src/express/referenceCount.I index f4d71b1117..870362ff14 100644 --- a/panda/src/express/referenceCount.I +++ b/panda/src/express/referenceCount.I @@ -424,7 +424,7 @@ RefCountObj(const Base ©) : Base(copy) { template void RefCountObj:: init_type() { -#if defined(HAVE_RTTI) && !defined(__EDG__) +#if defined(HAVE_RTTI) && !defined(__EDG__) && (!defined(__GNUC__) || defined(__GXX_RTTI)) // If we have RTTI, we can determine the name of the base type. std::string base_name = typeid(Base).name(); #else diff --git a/panda/src/putil/copyOnWriteObject.I b/panda/src/putil/copyOnWriteObject.I index bcf326d87c..a6afee7163 100644 --- a/panda/src/putil/copyOnWriteObject.I +++ b/panda/src/putil/copyOnWriteObject.I @@ -128,7 +128,7 @@ make_cow_copy() { template void CopyOnWriteObj:: init_type() { -#if defined(HAVE_RTTI) && !defined(__EDG__) +#if defined(HAVE_RTTI) && !defined(__EDG__) && (!defined(__GNUC__) || defined(__GXX_RTTI)) // If we have RTTI, we can determine the name of the base type. std::string base_name = typeid(Base).name(); #else @@ -188,7 +188,7 @@ make_cow_copy() { template void CopyOnWriteObj1:: init_type() { -#if defined(HAVE_RTTI) && !defined(__EDG__) +#if defined(HAVE_RTTI) && !defined(__EDG__) && (!defined(__GNUC__) || defined(__GXX_RTTI)) // If we have RTTI, we can determine the name of the base type. std::string base_name = typeid(Base).name(); #else