diff --git a/configure.py b/configure.py index 659881174..35128e380 100644 --- a/configure.py +++ b/configure.py @@ -564,7 +564,7 @@ config.libs = [ JSystemLib( "JParticle", [ - Object(NonMatching, "JSystem/JParticle/JPABaseShape.cpp"), + Object(Matching, "JSystem/JParticle/JPABaseShape.cpp"), Object(Matching, "JSystem/JParticle/JPAExtraShape.cpp"), Object(Matching, "JSystem/JParticle/JPASweepShape.cpp"), Object(Matching, "JSystem/JParticle/JPAExTexShape.cpp"), diff --git a/include/JSystem/JParticle/JPABaseShape.h b/include/JSystem/JParticle/JPABaseShape.h index 6081e4fbf..d50734ce9 100644 --- a/include/JSystem/JParticle/JPABaseShape.h +++ b/include/JSystem/JParticle/JPABaseShape.h @@ -28,7 +28,9 @@ public: static GXCompare stCompare[8]; static GXAlphaOp stAlphaOp[4]; - virtual ~JPABaseShape() {} + // ~JPABaseShape should defined in the header but that breaks the order of weak functions in JPABaseShape.cpp. + // Instead we define it in JPABaseShape.cpp in order to fakematch the order and explicitly mark it as inline. + inline virtual ~JPABaseShape(); virtual u8 getType() = 0; virtual u8 getDirType() = 0; virtual u8 getRotType() = 0; diff --git a/src/JSystem/JParticle/JPABaseShape.cpp b/src/JSystem/JParticle/JPABaseShape.cpp index 94eee2e81..b99ad2a94 100644 --- a/src/JSystem/JParticle/JPABaseShape.cpp +++ b/src/JSystem/JParticle/JPABaseShape.cpp @@ -163,3 +163,5 @@ JPABaseShapeArc::JPABaseShapeArc(const u8* data, JKRHeap* pHeap) { mpEnvColorArr = NULL; } } + +JPABaseShape::~JPABaseShape() {}