I guess this is not the real problem, but just a consequence of it.
Probably, this crash is because of a mis-initialization of XPCOM. You
can check this easily just adding a 'printf' before the return
statement at EmbedPrivate::PushStartup method

rv = NS_InitEmbedding(binDir, sAppFileLocProvider);
if (NS_FAILED(rv)) {
     printf ("The problem begins here\n");
     return;
}

Btw, have you tried building it with xulrunner's mozconfig either
(xulrunner/config/mozconfig). I've built and ran TestGtkEmbed from a
xulrunner build without problems ... check out
http://benjamin.smedbergs.us/blog/2006-01-12/mozilla-embedding-small-devices-and-gtkmozembed/
 and http://weblogs.mozillazine.org/dougt/archives/009576.html


I got it doing something like this :

cd base_dir
cp xulrunner/config/mozconfig .
make -f client.mk build_all
cd dist/bin
export GRE_HOME=.
./run-mozilla.sh ./TestGtkEmbed www.google.com

>  I'm trying to build an application embeding Gecko.
>
>  I am following the information obtained from
> http://www.mozilla.org/projects/embedding/
>  but I am finding myself a little lost.
>

I'm not quite sure about how updated are the info there ... :s

>  This is a run down of what I have attempted so far, feel free to point out
> anything that
>  is wrong or just plain stupid.
>  (I apologise in advance for the interleaving of explanations and output
> messages)
>
>  I downloaded the mozilla source tree from:
> ftp://ftp.mozilla.org/pub/mozilla.org/mozilla/releases/mozilla1.7.13/source/mozilla-1.7.13-source.tar.bz2
>
>  I then created a .mozconfig file in ~/Desktop/mozilla/ containing:
>  ac_add_options --enable-default-toolkit=gtk2
>
>  I then proceeded to build the source by:
>  make -f client.mk build
>
>  An hour and a half later the build finished without any apparent errors.
>  I then proceeded as follows to make an embedding build:
>
>  cd ~/Desktop/mozilla/embedding/config
>  make

>
>  Running ./run-mozilla.sh with -g gives a little more information:
>
>  0xb7f4c335 in EmbedPrivate::Realize (this=0x80a6df8,
> aAlreadyRealized=0xbf981534)
>      at EmbedPrivate.cpp:264
>  264         NS_STATIC_CAST(GdkWindow *,
>
>
>  Looking in EmbedPrivate.cpp on line 264 we have:
>
>
>    // get the native drawing area
>    GdkWindow *tmp_window =
>      NS_STATIC_CAST(GdkWindow *,
>             mozWidget->GetNativeData(NS_NATIVE_WINDOW));
>
>
>  And thats where i am now. Any information on what i have done wrong, what i
> need to do, or further links to resources about embeding Gecko into
> applications would be appreciated.


--
--Antonio Gomes
_______________________________________________
dev-embedding mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-embedding

Reply via email to