Can't compile bah.libxml on Mac OS X

BlitzMax Forums/BlitzMax Module Tweaks/Can't compile bah.libxml on Mac OS X

BugZilla(Posted 2009) [#1]
I need to get the LibXML module to work before I can get TimelineFX module to work on the Mac. I downloaded the only link I could find (pointed to a ZIP file). Problem is it won't compile. Using the BlitzMax IDE, I have Build all Modules and also tried Rebuild all modules. Has anyone been able to get this module to compile on the Mac?


Brucey(Posted 2009) [#2]
You can find the latest version here : http://code.google.com/p/maxmods/downloads/list?can=2&q=libxml

the folder libxml.mod should be dropped into the following location :

BlitzMax/mod/bah.mod/

You may need to create the bah.mod folder first.

After that, it should build okay.

Do you get any specific errors?


_JIM(Posted 2009) [#3]
If you got no errors, it probably means it compiled the bmx part, but not the c/c++ part, which is a sign that you don't have MinGW installed and/or configured correctly.


Beaker(Posted 2009) [#4]
Aah! That explains a problem I was having with a non-Brucey module on the Mac. Thanks JIM.

Something else I noticed on the PC IDE was the menu items for rebuilding modules are always greyed out. Anyone know why? I can compile from the command line no problem & seems fine on the Mac IDE.

Someone (Brucey?) should do a good guide to all this module compile stuff. Some of it is on his web/googlecode site, which is where I always look to find this stuff out (I forget often), but then it doesn't quite deliver (no real commandline details).


Brucey(Posted 2009) [#5]
Aah! That explains a problem I was having with a non-Brucey module on the Mac

Just to point out that MinGW isn't required on the Mac. :-)

Something else I noticed on the PC IDE was the menu items for rebuilding modules are always greyed out.

This is because you haven't configured (or installed?) MinGW properly. You need to add the location of MinGW/bin to your PATH environment variable, and add a new variable called MINGW which points to the main MinGW folder.

seems fine on the Mac IDE.

With XCode installed (required for all Mac compiling), everything should be fine.

You are right, I need a more detailed HOWTO kind of guide for building modules.


xlsior(Posted 2009) [#6]
This is because you haven't configured (or installed?) MinGW properly. You need to add the location of MinGW/bin to your PATH environment variable, and add a new variable called MINGW which points to the main MinGW folder.


Plus if you're using Vista / Windows 7 there's a few additional restrictions: IIRC you also need these environment variables:

C_INCLUDE_PATH=C:\MinGW\include;C:\MinGW\lib\gcc\mingw32\3.4.5\include
GCC_EXEC_PREFIX=c:\MinGW


Plus MinGW may need to be installed straight off the root directory, e.g. c:\mingw


Beaker(Posted 2009) [#7]
I must confess I was drunk when I wrote that post last night. :)

It's odd that stuff seems to compile ok from the command line (PC/XP). Or does that use different path vars? I've put the extra var in (path was already there). No change so far. I've either misspelt something, or missed a slash or need a reboot or added it to the wrong place. I'm sure I did this all fine on my older laptop.

Ho-hum. :D