views:

34

answers:

1

Hi folks,

I'd like to embed Mozilla's SpiderMonkey in one of my C apps. On linux, I don't think it'll be a problem (I'm a linux user) but I must confess that I'm afraid that I have no clue on how to do it on windows using MINGW (I want the app to be portable)

Is it possible to, say, just use the dll that comes with firefox? (I, honnestly, don't even know how to use dlls with MINGW)

Do you have any tips, hints, tutorials on how to build (or just embed spidermonkey) on windows using MINGW (I refuse to use Visual Studio :) )

Or do you have an alternative solution other than SpiderMonkey that's easy to use, and can do some basic javascript stuff (I don't need DOM for eg.) ?

Thanks a LOT!

+1  A: 

As far as I know Mozilla build it's software on Windows using MSVC.

https://developer.mozilla.org/En/Developer_Guide/Build_Instructions/Windows_Prerequisites

You may be on your own if building with Mingw32 is a must.

Vitor Py
Thanks, Vitor! Yes, I think so too :( I hate to depend on Microsoft tools actually and I won't use MSVC. And I'll probably better embed Lua if I have no other solutions
sandra
@sandra, did you take a look at this: http://jargon.ca/spidermonkey/? "Building Mozilla SpiderMonkey v1.7.0 on Windows XP using MinGW".
Vitor Py
Yes, thanks @Vitor I did but when I didn't like the fact that I needed some "modified" files :(
sandra
If your problem is modifying jsapi.c I suggest you to use a modern gcc version instead of the version Mingw32 ships by default. Take a look at here http://tdm-gcc.tdragon.net/. The build files are obviously have to be rebuilt anyway.
Vitor Py