Creating XPCOM module in C++ and VC

Lukas Haase <[email protected]> Fri, 31 Jan 2014 02:27:06 -0800
Newsgroups gmane.comp.mozilla.devel.plugins
Message-ID <[email protected]>
Hi all,

Is anyone successful in building a simple Hello-World XPCOM module for
current Firefox?

I can't get the current xulrunner-sdk working with VC and there is ZERO
doc with it (at least I don't find it). There are major syntax errors in
mozilla/TypeTraits.h which can only stem from an incompatibility or so.

For this reason, I used the SDK for Gecko 1.9.2 (Firefox 3.6). I can
successfully create a DLL based on outdated information:
https://developer.mozilla.org/en-US/docs/How_to_build_a_binary_XPCOM_component_using_Visual_Studio


I copy this DLL including its xpt file to the components directory of my
extension, add to chrome.manifest:

interfaces components/IMyComponent.xpt
binary-component components/MyComponent.dll

and to install.rdf:

<em:unpack>true</em:unpack>

But the module does not register (can't be found with XPCOMViewer).

The information I find is so inconsistent that I do not even know where
to start debugging.

Any idea? Any help?

Thanks so much
Luke