[geos-devel] Can't build geos with ruby swig bindings on Mac OS

Ramie Blatt rblatt at warmlyyours.com
Fri Oct 12 18:41:16 EDT 2007


Hi there,

I'm having quite a time of it trying to build geos with the ruby swig  
bindings on a MacBook Pro.

Any help on this issue would be appreciated.

When I try to build geos from any of the following releases  
(uninstalling between attempts):
[2006/12/14] geos-3.0.0rc3.tar.bz2
[2006/11/05] geos-3.0.0rc2.tar.bz2
[2006/09/09] geos-3.0.0rc1.tar.bz2

I get the following error at the make command:

----------------------------------------------
  g++ -DHAVE_CONFIG_H -I. -I. -I../../source/headers -I../../source/ 
headers/geos -I/usr/local/lib/ruby/1.8/i686-darwin8.9.1 -I../../capi - 
g -O2 -DGEOS_INLINE -Wall -ansi -pedantic -Wno-long-long -MT geos_la- 
geos_wrap.lo -MD -MP -MF .deps/geos_la-geos_wrap.Tpo -c  
geos_wrap.cxx  -fno-common -DPIC -o .libs/geos_la-geos_wrap.o
geos_wrap.cxx: In function 'void checkCoordSeqBounds(GEOSCoordSeq_t*,  
size_t)':
geos_wrap.cxx:1702: error: invalid conversion from 'size_t*' to  
'unsigned int*'
geos_wrap.cxx: In function 'int GeosCoordinateSequence_getSize 
(GeosCoordinateSequence*)':
geos_wrap.cxx:1844: error: invalid conversion from 'size_t*' to  
'unsigned int*'
geos_wrap.cxx: In function 'int GeosCoordinateSequence_getDimensions 
(GeosCoordinateSequence*)':
geos_wrap.cxx:1850: error: invalid conversion from 'size_t*' to  
'unsigned int*'
make[4]: *** [geos_la-geos_wrap.lo] Error 1
make[3]: *** [all-recursive] Error 1
make[2]: *** [all] Error 2
make[1]: *** [all-recursive] Error 1
make: *** [all-recursive] Error 1
----------------------------------------------

When I try to build geos from the [2007/02/02] geos-3.0.0rc4.tar.bz2  
release, everything seems to work, but then I can't actually load the  
geos code in ruby, getting the following error whenever "require  
'geos'" is encountered, even though I can see the geos.a, geos.la,  
and geos.so  files in the /usr/local/lib/ruby/site_ruby/1.8/i686- 
darwin8.9.1/  directory:

----------------------------------------------
 >> require 'geos'
MissingSourceFile: no such file to load -- geos
         from /usr/local/lib/ruby/site_ruby/1.8/rubygems/ 
custom_require.rb:27:in `gem_original_require'
         from /usr/local/lib/ruby/site_ruby/1.8/rubygems/ 
custom_require.rb:27:in `require'
         from ./script/../config/../config/../vendor/rails/ 
activerecord/lib/../../activesupport/lib/active_support/ 
dependencies.rb:147:in `require'
         from (irb):5
         from :0
----------------------------------------------


My environment, below, seems to be a good sane environment, and I run  
several ruby on rails applications.

Mac OSX 10.4.10
gcc version 4.0.1 (Apple Computer, Inc. build 5250)
libtool Apple Computer, Inc. version cctools-590.23.2
ruby 1.8.6 (2007-03-13 patchlevel 0) [i686-darwin8.9.1]
rails 1.2.3


Any help on this issue would be appreciated.

Regards,
Ramie Blatt

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/geos-devel/attachments/20071012/067806c6/attachment.html


More information about the geos-devel mailing list