[Chicken-users] Wrapping C++?

2016-10-22 Thread Josh Barrett
What's actually involved in wrapping a C++ class? The docs say I have to provide a class that contains the C++ instance pointer, but it doesn't say what to do with the instance pointer once it's in the scheme object, and how to wrap access to C++ functions and values. _

Re: [Chicken-users] Compiling a shared library from swig interface

2016-10-22 Thread Thomas Chust
On 2016-10-22 13:16, spalis wrote: > [...] > Error: (load) unable to load compiled module - ./example.so: undefined > symbol: _ZTV6Square: "./example.so" > [...] Hello, well, binutils tells us that $ c++filt _ZTV6Square vtable for Square So the shared object you built apparently does not link

[Chicken-users] Compiling a shared library from swig interface

2016-10-22 Thread spalis
I tried to get the following class example from swig running: /* File : example.cxx */ #include "example.h" #define M_PI 3.14159265358979323846 /* Move the shape to a new location */ void Shape::move(double dx, double dy) { x += dx; y += dy; } int Shape::nshapes = 0; double Circle::area()