编译bsp
1
| git clone https://github.com/starfive-tech/VisionFive2.git
|
1 2
| cd VisionFive2 git submodule update --init --recursive
|
安装工具链
1
| git clone --recursive https://github.com/riscv/riscv-gnu-toolchain
|
下载工具链
可以在https://toolchains.bootlin.com/下载交叉编译工具链。需要对指令集架构和libc进行选择,这里使用riscv 64和glibc,点击Download stable即可下载。
1
| xu1@ubuntu:~/test$ tar -xvf riscv64-lp64d--glibc--stable-2023.08-1.tar.bz2
|
编译内核
1 2 3 4 5 6 7 8
| cd $VF2_WORK_DIR git clone https://github.com/starfive-tech/linux.git pushd linux/ git checkout JH7110_VisionFive2_devel cp arch/riscv/configs/starfive_visionfive2_defconfig .config make ARCH=riscv CROSS_COMPILE=riscv64-linux-gnu- olddefconfig nice make ARCH=riscv CROSS_COMPILE=riscv64-linux-gnu- -j$(nproc) bindeb-pkg KDEB_COMPRESS=xz LOCALVERSION=-starfive popd
|
安装内核
1 2 3 4 5 6
| sudo cp $VF2_WORK_DIR/linux-image-5.15.0-*.deb ./riscv-chroot-snapshots/root sudo chroot $VF2_WORK_DIR/riscv-chroot-snapshots dpkg -i /root/*.deb mkdir /lib/firmware sync exit
|
6u工具编译
1 2 3 4 5 6 7 8 9 10 11 12 13
|
cd agate_6u/trunk/tools/acl/cfgm1 ./build_lib.sh
cd agate_6u/trunk/tools/acl/app sudo ./build.sh
cd agate_6u/trunk/tools/nanomsg ./build.sh
|
6u编译命令
1 2 3 4
| sudo ./build-db.sh l3 lskd5760
sudo ./build.sh rootfs
|
fpga代码库
1
| ssh://dnsnat@192.168.137.16/~/workspace/database/workspace/database/repertory/gateway_fpga
|
httpserver编译安装
1
| ./configure --prefix=/opt/web/lighttpd-1.4.30-x86 --host=i686-pc-linux --build=i686-pc-linux --disable-FEATURE --enable-shared --disable-static --disable-lfs --disable-ipv6 --without-PACKAGE --without-valgrind --without-openssl --without-kerberos5 --without-pcre --without-zlib --without-bzip2 --without-lua
|
php