Bug#676094: geos: FTBFS: geos_wrap.cxx:856:18: fatal error: ruby.h: No such file, or directory

peter green plugwash at p10link.net
Mon Jun 25 02:57:05 UTC 2012

tags 676094 +patch

Thia package failed to build after being imported to raspbian and I 
needed to get it building so I took a look.

I managed to fix the include file not found issue with some makefile hackery

Unfortunately after I fixed that I got

/bin/bash ../../libtool  --tag=CXX   --mode=compile g++ -fpermissive 
-DHAVE_CONFIG_H -I. -I../../include -I../../include/geos 
-I/usr/include/ruby-1.9.1/x86_64-linux/.. -I../../capi  -DGEOS_INLINE  
-pedantic -Wall -ansi -Wno-long-long  -ffloat-store -g -O2 -MT 
geos_la-geos_wrap.lo -MD -MP -MF .deps/geos_la-geos_wrap.Tpo -c -o 
geos_la-geos_wrap.lo `test -f 'geos_wrap.cxx' || echo './'`geos_wrap.cxx
libtool: compile:  g++ -fpermissive -DHAVE_CONFIG_H -I. -I../../include 
-I../../include/geos -I/usr/include/ruby-1.9.1/x86_64-linux 
-I/usr/include/ruby-1.9.1/x86_64-linux/.. -I../../capi -DGEOS_INLINE 
-pedantic -Wall -ansi -Wno-long-long -ffloat-store -g -O2 -MT 
geos_la-geos_wrap.lo -MD -MP -MF .deps/geos_la-geos_wrap.Tpo -c 
geos_wrap.cxx  -fPIC -DPIC -o .libs/geos_la-geos_wrap.o
geos_wrap.cxx: In function 'void SWIG_Ruby_define_class(swig_type_info*)':
geos_wrap.cxx:1517:9: warning: variable 'klass' set but not used 
geos_wrap.cxx: In function 'VALUE SWIG_AUX_NUM2DBL(VALUE*)':
geos_wrap.cxx:2658:9: warning: unused variable 'type' [-Wunused-variable]
geos_wrap.cxx: In function 'VALUE _wrap_create_polygon(int, VALUE*, VALUE)':
geos_wrap.cxx:7878:33: error: 'struct RArray' has no member named 'len'

I was able to hack arround this with a bit of sed magic on the generated 

However even after the build completed the package generation was 
unsuccesful as the packaging was all setup for ruby 1.8 . At this point 
I decided to give up on the ruby 1.9 approach. Patch for the final 
attempt of that approach is attatched as geos-ruby1.9.1-attempt.patch

At this point I decided to take a different approach, rather than try 
and make the package work with ruby 1.9.1 I instead decided to simply 
adjust the build-depends and build-conflicts so that the package was 
built against 1.8,

That gave me a succesful build. Patch for that adjustment is in 
geos-force-ruby1.8.patch . I have uploaded that patched version to 
raspbian, I have not uploaded it to debian as I have no idea how to test 
the package actually works. I also noticed that at the end of the build 
my changes to debian/control were getting obliterated. Looks like the 
changes in the patch should really be applied to control.in as well as 
to control if you go down this route.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: geos-ruby1.9.1-attempt.patch
Type: text/x-diff
Size: 5661 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-grass-devel/attachments/20120625/c8b36864/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: geos-forceruby1.8.patch
Type: text/x-diff
Size: 614 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-grass-devel/attachments/20120625/c8b36864/attachment-0001.patch>

More information about the Pkg-grass-devel mailing list