Heads-up on libxml compile error on ubuntu 9.04

BlitzMax Forums/Brucey's Modules/Heads-up on libxml compile error on ubuntu 9.04

Jim Teeuwen(Posted 2009) [#1]
I just tried rebuilding some of the bah.mod modules (updated to latest versions off googlecode). I found the compiler failed on bah.mod/libxml.mod/src/nanohttp.c.
After some googling it turns out it's because of some changes in glibc and the following is listed as the 'best practise fix' for this.

The error thrown was:
error: call to '__open_missing_mode' declared with attribute error: open with O_CREAT in second argument needs 3 arguments

To fix this, add:
#include <sys/stat.h>

to the top of nanohttp.c, and change line 1586 from:
fd = open(filename, O_CREAT | O_WRONLY);

to this:
fd = open(filename, O_CREAT | O_WRONLY, S_IRUSR|S_IWUSR);

Brucey(Posted 2009) [#2]

Yes, I should really catch up with some of my releases.

It is fixed in SVN.