1.用交叉编译器编译时,也会出现找不到sqlite3.h头文件的情况,需要把sqlite3.h这个头文件放到交叉编译工具目录下的 include
2.mips64el-redhat-linux-g++ sqlite.c -lm -o sql_test -static -L/opt/gcc-4.4.7-7215-n64-loongson/usr/mips64el-redhat-linux/sysroot/lib64 -lsqlite3 -lpthread -ldl
3.export PATH=/opt/gcc-4.4.7-7215-n64-loongson/usr/bin:
P
A
T
H
4.
p
m
o
n
编
译
e
x
p
o
r
t
P
A
T
H
=
/
o
p
t
/
g
c
c
−
4.4
−
g
n
u
/
b
i
n
/
:
PATH 4.pmon编译 export PATH=/opt/gcc-4.4-gnu/bin/:
PATH4.pmon编译exportPATH=/opt/gcc−4.4−gnu/bin/:PATH
make tgt=rom CROSS_COMPILE=mipsel-linux- DEBUG=-g
make dtb
cp gzrom-dtb.bin /mnt/hgfs/share/longxi/ls2k/BIN/gzrom-dtb-pi.bin
sata调试
1、移植mke2fs
https://blog.csdn.net/sunlion81/article/details/9943963
2、./mke2fs -t ext4 -L ‘testdisk’ /dev/sda1
3、mount /dev/sda1 /sata -t ext4
pmon启动参数在Makefile.inc中