|
|
|
#1 |
|
Registered User
Join Date: Jun 2006
Posts: 11
|
V3 plugin compilation in VC++ 2005 Express Edition
Hi,
I just trided to build your example plugin in VC++ 2005 EE + WinSDK Problems I encountered were as follows: 1. You use atlbase.h in your project, that requires atlthug.lib (not present in Express Edition) - I solved (I think:-) ) this problem using solutions from http://www.mozillapl.org/forum/about-21894.html - section about modifying (modifications needed: |. Go to the \include\atl folder under the PSDK directory, and: |* in atlbase.h around line 300 change the block around "#pragma include |atlthunk.lib" to: | |[...] |}; |#pragma pack(pop) | |/* |PVOID __stdcall __AllocStdCallThunk(VOID); |VOID __stdcall __FreeStdCallThunk(PVOID); | |#define AllocStdCallThunk() __AllocStdCallThunk() |#define FreeStdCallThunk(p) __FreeStdCallThunk(p) | |#pragma comment(lib, "atlthunk.lib") |*/ | |// workaround for not having atlthunk.lib in PSDK or VC++ 2005 Express |Edition |#define AllocStdCallThunk() HeapAlloc(GetProcessHeap(),0,sizeof |(_stdcallthunk)) |#define FreeStdCallThunk(p) HeapFree(GetProcessHeap(), 0, p) | |#elif defined (_M_AMD64) |#pragma pack(push,2) |[...] | |* in atlwin.h around line 1753, replace "for(i = 0;" with "for(int i = 0;" |Now the PSDK should be fixed in a way that we can build ATL stuff using it. |Unfortunately MFC still doesn't work (see below). ) 2. Second problem: during building the callDLL I get this error, and have no idea what the problem is and how to solve it: ------ Build started: Project: CallDLL, Configuration: Release Win32 ------ Linking... StdAfx.obj : warning LNK4229: invalid directive '/FILEALIGN:0x200' encountered; ignored StdAfx.obj : warning LNK4229: invalid directive '/IGNORE:4078' encountered; ignored Creating library .\Release/CallDLL.lib and object .\Release/CallDLL.exp NC_Plugin.lib(NC_Plugin.obj) : error LNK2019: unresolved external symbol "void * __cdecl On_NC_Construct(unsigned short * const)" (?On_NC_Construct@@YAPAXQAG@Z) referenced in function _OnLoad@4 .\Release/CallDLL.dll : fatal error LNK1120: 1 unresolved externals Build log was saved at "file://c:\cd_record\CD_licence\SWFStudio_Inspiria_license\examples\plugin_develop\CallDLL\Release\BuildLog.htm" CallDLL - 2 error(s), 2 warning(s) ========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ========== Any Idea, Maybe it is still the problem of Express Edition. Do you think Full version of VC++ 2005 will help? And maybe is it possible to get Plugin example especially for VC 2005? regards, Daniel (Inspiria) |
|
|
|
|
|
#2 |
|
Plugin Developer
Join Date: Jun 2002
Location: Germany
Posts: 2,409
|
At least it builds fine with VC++ 6, haven´t tried the newer version, though.
I plan to switch next week, I´ll let you know if you do not find a solution in the meantime. |
|
|
|
|
|
#3 |
|
Registered User
Join Date: May 2003
Location: Ottawa
Posts: 416
|
inspira,
Save yourself some grief. Don't include atlbase.h. It was there strictly for the definition of BSTR (VC6), which is now treated as an internal type (see Solution Properties / Configuration Properties / C++ / Language / Treat wchar_t as Built-in type). The unresolved external implies that your project is missing a line of code. Is there an IMPLEMENT_PLUGIN(class_name) in your code? Dan |
|
|
|
|
|
#4 | |
|
Registered User
Join Date: Jun 2006
Posts: 11
|
Quote:
|
|
|
|
|