[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Arx-users] Chicken bindings progress
From: |
Walter Landry |
Subject: |
Re: [Arx-users] Chicken bindings progress |
Date: |
Sat, 23 Jul 2005 22:16:45 -0700 (PDT) |
Peter Busser <address@hidden> wrote:
> Hi!
>
> I have hacked a bit at the Python arx.i and it seems to compile to a Chicken
> module now.
>
> If anyone is interested, this is what I changed in python/arx.i:
>
> --- python/arx.i 2005-07-23 20:06:36.000000000 +0200
> +++ chicken/arx.i 2005-07-23 16:27:26.000000000 +0200
> @@ -119,9 +119,9 @@
> #include "xdelta.hpp"
> %}
>
> -%include "std_string.i"
> -%include "std_list.i"
> -%include "std_map.i"
> +#%include "std_string.i"
> +#%include "std_list.i"
> +#%include "std_map.i"
Ah, I guess there is no standard conversion for these things into
chicken.
> # We have to include our own version of boost/filesystem/path.hpp
> # because the included definition has a nested class.
>
> And this is the script used to generate the .so file:
> #!/bin/sh
>
> swig -chicken -c++ -I../include -I../../boost arx.i
>
> csc -shared -C -I../include -C -I../../boost -C -I/usr/include/gnome-vfs-2.0
> -C -I/usr/include/glib-2.0 arx.scm arx_wrap.cxx -C
> -I/usr/lib/glib-2.0/include/ -C -I../../loki -L ../../../build/loki/libloki.a
> -L ../../../build/boost/libboost.a
>
> This assumes that 1) ArX has been built (so that the correct libraries are
> available) and 2) the script is run from src/arx/chicken.
>
> However, I get the following error message:
> "/usr/lib/chicken/arx.so: undefined symbol: _ZN12Command_Info9verbosityE"
For this particular symbol, You have to compile and link in
"static_initializer.cpp" in src/arx/python. It sets a static
variable.
> This probably means the correct ArX object files have not been
> linked into the module. However, I could not find a libarx.a or
> libarx.so or something like that. Which ArX object files are needed
> for these language bindings to work?
If you build the python bindings, there will be both a libarx.a and
libarx.so in build/arx. You will have to link that in as well. It
might be possible to hack the SConscript file, but I don't think that
SCons understands chicken :(
Cheers,
Walter