A list for the developers of CellML tools

Text archives Help


[cellml-dev] CellML wchar sizes


Chronological Thread 
  • From: ak.miller at auckland.ac.nz (Andrew Miller)
  • Subject: [cellml-dev] CellML wchar sizes
  • Date: Wed, 09 Dec 2009 13:45:52 +1300

Lucian Smith wrote:
> So, I'm still not sure when I need to use getter_AddRefs() and when I
> don't, but so far it seems the answer is 'everywhere' which is annoying,
> but there you go. I *finally* got all my old code translated into the new
> regime, faked up some string to nsString converters (which I'm sure will
> fail horribly if ever used for real unicode, but at this point I don't
> care), so I got it to actually run. And it immediately failed:
>
> nsresult rv;
> nsCOMPtr<cellml_apiICellMLBootstrap>
> boot(do_GetService(CELLML_BOOTSTRAP_CONTRACTID, &rv));
> NS_ENSURE_SUCCESS(rv, -1);
>
> 'rv' turned out to be 2147746132, which wasn't very helpful, but I managed
> to translate that into hex via google, then look *that* up in nsError.h
> and finally found out that it means "NS_ERROR_FACTORY_NOT_REGISTERED".
>
> I don't know how to register a factory, and actually have a very dim idea
> of what a factory is in the first place. Help?

Are you running this with xulrunner, or through your own code directly
using XPCOM? If the latter, are you requesting XPCOM components be
registered?

If you are using xulrunner, or are registering XPCOM components, are the
CellML XPCOM components in the correct components directory? Is your
PATH or LD_LIBRARY_PATH, depending on the platform, correct, so that the
CellML API libraries are in the loader path (the shared objects
themselves, not the .la files from libtool)?

If you are using xulrunner, have you forced XPCOM component
re-registration, e.g. by deleting compreg.dat from the profile
directory, to ensure you don't have a stale version from an earlier run
when the paths were wrong?

Using a debug build of Mozilla, or tracing what the dynamic loader is
doing (using LD_DEBUG=files on glibc based systems, or by enabling the
show loader snaps flag on Windows systems), after removing compreg.dat,
can help narrow down the cause of XPCOM component registration failures.

Best wishes,
Andrew

>
> -Lucian
> _______________________________________________
> cellml-tools-developers mailing list
> cellml-tools-developers at cellml.org
> http://www.cellml.org/mailman/listinfo/cellml-tools-developers





Archive powered by MHonArc 2.6.18.

Top of page