Hi, everyone.
In fact, I use libtcc.so in http://www.cs.tut.fi/~ask/cinpy/, which is
a Python(www.python.org) library can implement functions with C in
Python script directly.

My question is, how to set the 'include' path, so that libtcc.so can
find it. Thanx
The following python exits with "ValueError: tcc_relocate returned
error code -1."
[code]
import ctypes
import cinpy
fraction=cinpy.defc("fraction",
               ctypes.CFUNCTYPE(ctypes.c_float,None),
               """
               #include "stdlib.h"
               #include "stdio.h"
               #include "math.h"

               float fraction(void)
               {
                return sin(3.1415926/6); //that will err
                //return 1; //but this will be ok
                }
                """)
                                
print fraction()
[/code]


_______________________________________________
Tinycc-devel mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/tinycc-devel

Reply via email to