下载了一个linux环境下的开源工具,结果在mac的gcc环境中编译的时候,报错 error: malloc.h: No such file or directory

解决方法:将报错文件中

#include <malloc.h>

修改为

#include <sys/malloc.h>