[Project_owners] Re: class vs contract ids
enndeakin at sympatico.ca
Fri Sep 12 13:11:57 EDT 2003
>Pete Collins <pete at mozdev.org> wrote:
>>>Why isn't there simply a version for all platforms available for download?
>>A version of what? The xpidl compiler? That could actually be a good
>>idea for a mozdev project.
>Yeah, that's what I had in mind ;)
>>>So, for example, if you have 50 people (just a small number) that like to add their own component to the mozilla browser, they ALL have to go hell week first, why is that?
>>Unfortunately you need an xpidl compiled xpt type library in order for
>>you component to be scriptable if you want to play in the xpcom world.
>Well, having the XPIDL compiler available, for all platforms, and providing some basic steps to actually 'build' the .xpt file would solve a lot for this ridiculous, error phrone, time killing process...
Pre-compiled versions of xpidl and other tools are provided with the
Gecko SDK which is only 2.5MB on Windows (6MB on Linux). They're in the
nightly builds directory. In the SDK, look for geck-sdk/xpcom/bin/xpidl.
The only other thing you might need are headers and idl files for
Some short xpidl docs:
xpidl -m header -w <include-paths> -o <outputdir> <filename.idl>
xpidl -m typelib -w <include-paths> -o <outputdir> <filename.idl>
Do both of those once for each IDL file. <include-paths> should be a
list of directories where other IDL files you use are loacted. The first
command generates the header file (.h) and the second generates an xpt file.
Once done, use xptlink, which links all of the xpt files together:
xptlink <final-filename.xpt> <list-of-xpt-files>
The list of xpt files should be the ones generated with xpidl. This
command should only be run once. It will generate a final xpt file which
you should place in the Mozilla components directory.
You may need to set the MOZILLA_FIVE_HOME and/or LD_LIBRARY_PATH
environment variables to your Mozilla directory when using the tools. Do
this if a relocation error occurs.
When running Mozilla, delete components/compreg.dat and
components/xpti.dat if something doesn't register properly. Also try
using regxpcom (also included with the Gecko SDK).
More information about the Project_owners