raspberry bi 的 C 程序编写
linux 都带了 gcc, 简单程序可以在树莓派中,直接编译 复杂的程序,可以用 bcm (因为芯片是 broadcom 的) 的 toolchain 来编译 先下载工具包
设置toolchain的路径
可以编译了 arm-linux-gnueabihf-gcc main.c 也可以写个Makefile CC ?= $(CROSS_COMPILE)gcc 用下面命令编译 make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- http://hertaville.com/2012/09/28/development-environment-raspberry-pi-cross-compiler/ http://raspberrypi.stackexchange.com/questions/5599/how-to-compile-c-files-in-terminal (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |