Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- test by kyoung chip , jang
- sudo apt-get install python-dev
- sudo apt-get install python3-dev
- gcc -o p1 p1.c -I/usr/include/python2.7 -lpython2.7
- */
- #include <Python.h>
- int main( void )
- {
- Py_Initialize();
- PyRun_SimpleString("import sys; sys.path.append('.')");
- PyRun_SimpleString("import callme;");
- PyRun_SimpleString("print( callme.test(\"test\") ) ");
- Py_Finalize();
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement