golang 调用c代码
首先先上代码,看看效果。package main/*#include <stdio.h>void sayHello(){ printf("hello, world!");}*/import "C"func main(){ C.sayHello()}如果在执行时报错exec: "gcc": executable file not found in %PATH%,可以查看executable file