#include <stdio.h> char *get_str() { return "hello,world" }
from ctypes import * dll = CDLL("./hello.so") dll.get_str.restype = c_char_p str = dll.get_str() print(string_at(str, 11))
[feng@arch python_c]$ python test.py hello,world
以上就是python如何调用c语言函数的使用详解的详细内容,更多请关注Gxl网其它相关文章!
查看更多关于python如何调用c语言函数的使用详解的详细内容...
声明:本文来自网络,不代表【好得很程序员自学网】立场,转载请注明出处:http://www.haodehen.cn/did84385