[postgis-devel] Compile issues on MingW trunk

Mark Cave-Ayland mark.cave-ayland at siriusit.co.uk
Fri Jan 23 09:20:22 PST 2009


Obe, Regina wrote:

> Mark,
> On closer inspection I see that asprintf and so forth are supposed to be
> defined in stdio.h.
> 
> My stdio.h under MingW doesn't have these functions and in fact looks
> very different from this one and doesn't even have a copyright notice
> 
> http://linux.die.net/include/stdio.h
> 
> My msys doesn't seem to have stdio.h aside from sources I've downloaded
> which do have these functions.
> 
> So maybe my base libraries need to be upgraded.
> 
> Can you let me know if you have luck compiling this under MingW?  If you
> do, then I'll assume its just something wrong with my install which
> wouldn't be all that surprising since I don't know what I'm doing :).
> 
> I'm pretty sure I was able to compile trunk under MingW until we started
> introducing these new fangled things.
> 
> Thanks,
> Regina 

I see it. The MS C runtime doesn't contain vasprintf() or asprintf() 
which is why we include our own versions in liblwgeom. According to 
http://svn.refractions.net/postgis/trunk/liblwgeom/vsprintf.c, adding a 
lw_ prefix to both should solve this for you.


HTH,

Mark.

-- 
Mark Cave-Ayland
Sirius Corporation - The Open Source Experts
http://www.siriusit.co.uk
T: +44 870 608 0063



More information about the postgis-devel mailing list