Hello everyone,
I am trying to create a FF extension which implements XPCOM component. I built my component as a DLL following this nice guide: http://www.iosart.com/firefox/xpcom/ My component uses two external DLLs: lib1.dll and lib2.dll. Known issue here is that FF does not load external DLLs automatically. If I put these libs into WINDOWS\system32 folder - everything works fine. Here is the short guide how to overcome this problem: https://developer.mozilla.org/en/Using_Dependent_Libraries_In_Extension_Components Solution is to create stub DLL which will load all my real DLLs.
My problem is: I don't understand how to create XPT file for stub component and how to package extension which uses stub dll. Previously to create XPT file I had to create IDL file first, and describe my method, which should be exposed to javascript. In stub dll I don't have anything which should be exposed to javascript. Should old XPT file be working? Now I am getting error
"Type Error: Components.classes[cid] is not defined"
which apparently means that my method does not get exported.
Initially my extension had the following structure: chrome components IMyComponent.xpt Component.dll chrome.manifest install.rdf
Following the guide on stub DLLs extension structure is the following:
chrome components component_stub.dll component_stub.xpt <- how to get this file? Should IMyComponent.xpt work?.. libraries lib1.dll lib2.dll Component.dll <- my real component chrome.manifest install.rdf
Any hints on how to debug this are highly appreciated! Thanks a lot!
Robusta