From: MARTIN P. <hic...@gm...> - 2012-04-18 15:27:08
|
> Are you building RELib? It should only be used when building it, not > when using it. I have no idea what Q_DECL_EXPORT is, you'll need to give > more information. i am (It is one of the many binaries i maintain). i only use RELib when building it of course. About the Q_DECL_EXPORT macro, it gets expanded like that (qglobal.h around line #1259 from the Qt 4.8.1 SDK): // For the current issue, Q_OS_WIN is defined. #if defined(Q_OS_LINUX) && defined(Q_CC_RVCT) # define Q_DECL_EXPORT __attribute__((visibility("default"))) # define Q_DECL_IMPORT __attribute__((visibility("default"))) # define Q_DECL_HIDDEN __attribute__((visibility("hidden"))) #endif // Look here, that's what gets defined when compiling RELibrary. #ifndef Q_DECL_EXPORT # if defined(Q_OS_WIN) || defined(Q_CC_NOKIAX86) || defined(Q_CC_RVCT) # define Q_DECL_EXPORT __declspec(dllexport) // So Q_DECL_IMPORT is expanded to __declspec(dllexport) when compiling RELibrary, which is correct. # elif defined(QT_VISIBILITY_AVAILABLE) # define Q_DECL_EXPORT __attribute__((visibility("default"))) # define Q_DECL_HIDDEN __attribute__((visibility("hidden"))) # endif # ifndef Q_DECL_EXPORT # define Q_DECL_EXPORT # endif #endif // Look here, that's what gets defined when importing RELibrary. #ifndef Q_DECL_IMPORT # if defined(Q_OS_WIN) || defined(Q_CC_NOKIAX86) || defined(Q_CC_RVCT) # define Q_DECL_IMPORT __declspec(dllimport) // So Q_DECL_IMPORT is expanded to __declspec(dllimport) when importing RELibrary, which is correct. # else # define Q_DECL_IMPORT # endif #endif #ifndef Q_DECL_HIDDEN # define Q_DECL_HIDDEN #endif > I don't know, call convention mixup? The linker is known to fixup > stdcalls from bad coding practices, but I'm not sure if this applies to > delay loaded DLLs. Hm ok. i have no idea what to do next... i'll see later. If you have any other idea, i'd be very happy to get them from you. Thanks a lot JonY, Pierre. |