Even though scc's response was 100% correct, and my other response was
somewhat related to your problem, neither is the quick answer you were
looking for.

The quick answer is: make sure you compile everything consistently with
OR without -DDEBUG.

-re

Bill Gerba wrote:
> 
> A few weeks ago I started working with mozilla to develop a Java-enabled
> web browser for Internet kiosks on Linux.  I was building off the
> SkipStone embedded browser, which was based on mozilla 0.7 and supported
> Java.  When I upgraded to the moz 0.8 source, I ran into compilation
> errors with SkipStone because the linker couldn't find the destructor
> for nsCOMPtr_base (from nsCOMPtr.h) in libxpcom.so.  Also, I noticed
> that Java would not load in 0.8, and despite following instructions from
> a dozen web pages and bug reports, I couldn't get mozilla to recognize
> the plugin at all.
> 
> Eventually, I "fixed" my SkipStone compilation errors by commenting out
> all lines with the variable NSCAP_FEATURE_FACTOR_DESTRUCTOR in
> nsCOMPtr.cpp and nsCOMPtr.h (all #defines, #ifdefs, and #ifndefs).  It
> seems like a very brute-force way to handle the issue, since I have no
> idea why it's there or what purpose it serves, but after that SkipStone
> compiled and ran, and had Java support.  What was most suprising is that
> this also mysteriously restored Java support in moz 0.8, which now
> recognizes the plugin at startup.  Just to be sure, I uncommented the
> references to NSCAP_FEATURE_FACTOR_DESTRUCTOR and recompiled the xpcom
> directory, which broke Java again; commenting it out again restored
> functionality.  I ran nm on libjavaplugin_oji.so, and it does have a
> reference to _._13nsCOMPtr_base (i.e. the destructor for nsCOMPtr_base),
> which was not in libxpcom.so until I waved my magic comments into the
> nsCOMPtr.* files and rebuilt it.
> 
> Here's my dilemma:  I don't see this fix as a legitimate solution to
> either of these problems.  I don't understand why this works at all.
> Both mozilla and SkipStone seem to crash from regular browsing more
> often than before, although that might just be instability in the 0.8
> release.  I'd like to get an opinion on this from someone who knows a
> lot more about this part of mozilla than I do.  Was
> NSCAP_FEATURE_FACTOR_DESTRUCTOR added or changed since 0.7?  Why would
> this have anything to do with the Java plugin?  This whole situation is
> a little beyond me, so please forgive me if some of this isn't too
> coherent.  Any help or advice would be greatly appreciated.
> 
> -Matt

Reply via email to