Hi, With xpidl.py, I got IFpComponent.h and FpComponent.xpt, however, I did not link project successfully, always tips me the error, below: 1>xpcomglue_s_nomozalloc.lib(nsISupportsImpl.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in FpComponent.obj In the preprocessor, I added XP_WIN and XP_WIN32; In the codegeneration, I selected Multi-threaded Debug DLL(/MDd); In the Input of the Linker, I fill mozalloc.lib; nspr4.lib; plds4.lib; plc4.lib; xpcomglue_s_nomozalloc.lib; xpcom.lib at Additional Dependencies; The following is the part of my code: /******************************************************** ** FpComponent.h ********************************************************/ #pragma once #ifndef _FP_COMPONENT_H_ #define _FP_COMPONENT_H_ #include "IFpComponent.h" #define FUNPLAYER_COMPONENT_CONTRACTID "@funshion.com/fpcomponent;1" #define FUNPLAYER_COMPONENT_CLASSNAME "Funshion player's XPCOM" #define FUNPLAYER_COMPONENT_CID { 0xedee1598, 0xaa95, 0x4325, { 0xa3, 0x25, 0xc5, 0x64, 0x3c, 0x50, 0xcc, 0x3e } } class CFpComponent : public IFpComponent { public: CFpComponent(void); ~CFpComponent(void); NS_DECL_ISUPPORTS NS_DECL_IFPCOMPONENT }; #endif /******************************************************** ** FpComponent.cpp ********************************************************/ #include "stdafx.h" #include "FpComponent.h" CFpComponent::CFpComponent( void ) {} CFpComponent::~CFpComponent( void ) {} NS_IMPL_ISUPPORTS1(CFpComponent, IFpComponent) NS_IMETHODIMP CFpComponent::Startup( void ) { MessageBoxA(NULL, "Hello World!", "tip", NULL); return NS_OK; } I use Gecko18 lib and include, however, I still not link successfully. Anyone could tell me the reason? Any tip will appreciate. Chris |
_______________________________________________ dev-tech-layout mailing list [email protected] https://lists.mozilla.org/listinfo/dev-tech-layout

