Having some simple runtime packages working fine for years. Changed the location of the source directories, now I get linker errors.
- A.bpl defines and implements class CMyClass, compiles and links fine.
- B.bpl uses this class, compiles and links fine.
- C.exe uses both packages but wouldn't link:
[Linker Error] Unresolved external 'CMyClass::CMyClass()' referenced from B.lib|B.cpp
[Linker Error] Unresolved external 'CMyClass::~CMyClass()' referenced from B.lib|B.cpp
[Linker Error] Unresolved external 'CMyClass::Open(void *)' referenced from B.lib|B.cpp
[Linker Error] Unresolved external 'CMyClass::Set(const System::AnsiString&)' referenced from B.lib|B.cpp
Using tdump on A.obj and B.obj it turns out that C++ method names are mangled a bit different in the two files. (I'm using the same probject settings for all packages.)
Now if I try to compile B.cpp into A.bpl, I got linker errors again:
[Linker Error] Export CMyClass::CMyClass() in module A.OBJ references __fastcall System::AnsiString::AnsiString() in unit A.BPL
etc.
The previously compiling project hasn't been altered since (except from inserting B.cpp into it). It links to VCL et al.
Any help would be appreciated.
BCB6sp4.
- A.bpl defines and implements class CMyClass, compiles and links fine.
- B.bpl uses this class, compiles and links fine.
- C.exe uses both packages but wouldn't link:
[Linker Error] Unresolved external 'CMyClass::CMyClass()' referenced from B.lib|B.cpp
[Linker Error] Unresolved external 'CMyClass::~CMyClass()' referenced from B.lib|B.cpp
[Linker Error] Unresolved external 'CMyClass::Open(void *)' referenced from B.lib|B.cpp
[Linker Error] Unresolved external 'CMyClass::Set(const System::AnsiString&)' referenced from B.lib|B.cpp
Using tdump on A.obj and B.obj it turns out that C++ method names are mangled a bit different in the two files. (I'm using the same probject settings for all packages.)
Now if I try to compile B.cpp into A.bpl, I got linker errors again:
[Linker Error] Export CMyClass::CMyClass() in module A.OBJ references __fastcall System::AnsiString::AnsiString() in unit A.BPL
etc.
The previously compiling project hasn't been altered since (except from inserting B.cpp into it). It links to VCL et al.
Any help would be appreciated.
BCB6sp4.