首先克隆git仓库:
git clone https://github.com/git/git
安装必要的.h头文件
sudo apt install libcurl4-openssl-dev libexpat1-dev
之后设置cc为arm-rockchip830-linux-uclibcgnueabihf-gcc
,交叉编译即可:
cd git
mkdir bin
cc=arm-rockchip830-linux-uclibcgnueabihf-gcc make install prefix=./bin
然后进行打包:
cd bin
tar cvf git.tar ./bin ./share ./libexec
然后,把打包的文件push到luckfox上面去:
adb push ./bin/git/git.tar ./home
之后去luckfox里解包就可以了。
tar xvf git.tar