[geos-devel] Status (New Example)

Norman Vine nhv at cape.com
Sun Apr 6 21:02:30 EDT 2003


Dave Blasby writes:
>
> Quoting Norman Vine <nhv at cape.com>:
>
> >
> > Let me try that again I cleaned up to much of
> > my debugging 'cruft' from my earlier files
>
> I've tried running your files, but I get the same results as
> before.  (I put
> the words "norman" in so I was sure it was using the correct .o files).
>
> I had a though on friday that the c++ wrapper ("test_cpp.cpp")
> might need more
> compile options than "-c"; say something like "-fpic".
>

Curious ?

Here is what I get with Cygwin and gcc 3.2

==== cut makeit.sh ====
#!/usr/bin/bash

HEADERS="../../source/headers"
LIBS="../source/geom/.libs/"

g++ -I${HEADERS} -c test_cpp.cpp
gcc -I./ -o test test.c test_cpp.o -L${LIBS} -lgeos -lstdc++

./test
===== cut ====

<530>
$ ./makeit
geom text (to be parsed):POLYGON((100 200,100 140,180 140,180 200,100 200))

geom (WKTWriter):POLYGON ((100.0000000000000000 200.0000000000000000,
100.0000000000000000 140.0000000000000000, 180.000
0000000000000 140.0000000000000000, 180.0000000000000000
200.0000000000000000, 100.0000000000000000 200.0000000000000000
))

result in C is POLYGON ((100.0000000000000000 200.0000000000000000,
100.0000000000000000 140.0000000000000000, 180.00000
00000000000 140.0000000000000000, 180.0000000000000000 200.0000000000000000,
100.0000000000000000 200.0000000000000000))





More information about the geos-devel mailing list