[geos-devel] GEOS C API Suggestions

strk at refractions.net strk at refractions.net
Mon Oct 17 10:36:40 EDT 2005

On Mon, Oct 17, 2005 at 09:25:23AM -0400, Frank Warmerdam wrote:
> On 10/17/05, strk at refractions.net <strk at refractions.net> wrote:

> > mmm.. so you can use the "stabler" API from C++ you mean ?
> > Sounds fair... I'll try to figure out how to do this.
> My main motivation is that I was unable to build GEOS with VC6
> on Win32 but I want to use it in my FWTools distribution.  It seems
> to be not possible to have VC6 C++ code call a VC7 C++ DLL;
> however, VC6 C calls into a VC7 DLL should be OK.
> More generally though I am hoping the C API will be more stable and
> hopefully make it easier to substitute use of JTS compiled with gcj
> for comparison.

I've fixed a typedef problem I encountered with C++ compiler
and added the extern "C" namespace when __cplusplus is defined.
The latter was unneeded for g++.
Does it work for you now ?
Does it work w/out the extern "C" part as well ?

> > >  4) I think the GEOS C entry points should be DLL exported.
> >
> > I'm not sure I understand this. Aren't them exported already ?
> I saw no sign that the C API had the dllexport attribute on the functions
> for win32.   I haven't tried things on win32 yet so perhaps I am missing
> something.

There is no dllexport attribute on any other GEOS function, that's why
I wondered. As you know I won't try things on win32 so I'll wait for
any problem report before attempting at any modification here.


More information about the geos-devel mailing list