-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathgit_linux_mpfs.sh
More file actions
executable file
·59 lines (43 loc) · 2.5 KB
/
git_linux_mpfs.sh
File metadata and controls
executable file
·59 lines (43 loc) · 2.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
#!/bin/bash
HSS_BRANCH="v2023.02"
HSS_REPO="https://github.com/polarfire-soc/hart-software-services.git"
#UBOOT_BRANCH="mpfs-uboot-2022.01"
UBOOT_BRANCH="linux4microchip+fpga-2023.02"
UBOOT_REPO="https://github.com/polarfire-soc/u-boot.git"
LINUX_BRANCH="linux4microchip+fpga-2023.06"
LINUX_REPO="https://github.com/linux4microchip/linux.git"
#LINUX_BRANCH="master"
#LINUX_REPO="https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git"
GIT_DEPTH="20"
if [ ! -f ./mirror/x86_64-gcc-11.4.0-nolibc-riscv64-linux.tar.xz ] ; then
echo "wget -c --directory-prefix=./mirror/ https://mirrors.edge.kernel.org/pub/tools/crosstool/files/bin/x86_64/11.4.0/x86_64-gcc-11.4.0-nolibc-riscv64-linux.tar.xz"
wget -c --directory-prefix=./mirror/ https://mirrors.edge.kernel.org/pub/tools/crosstool/files/bin/x86_64/11.4.0/x86_64-gcc-11.4.0-nolibc-riscv64-linux.tar.xz
fi
if [ ! -f ./riscv-toolchain/bin/riscv64-linux-gcc-11.4.0 ] ; then
echo "tar xf ./mirror/x86_64-gcc-11.4.0-nolibc-riscv64-linux.tar.xz --strip-components=2 -C ./riscv-toolchain/"
tar xf ./mirror/x86_64-gcc-11.4.0-nolibc-riscv64-linux.tar.xz --strip-components=2 -C ./riscv-toolchain/
fi
#if [ ! -f ./mirror/x86_64-gcc-13.2.0-nolibc-riscv64-linux.tar.xz ] ; then
# echo "wget -c --directory-prefix=./mirror/ https://mirrors.edge.kernel.org/pub/tools/crosstool/files/bin/x86_64/13.2.0/x86_64-gcc-13.2.0-nolibc-riscv64-linux.tar.xz"
# wget -c --directory-prefix=./mirror/ https://mirrors.edge.kernel.org/pub/tools/crosstool/files/bin/x86_64/13.2.0/x86_64-gcc-13.2.0-nolibc-riscv64-linux.tar.xz
#fi
#if [ ! -f ./riscv-toolchain/bin/riscv64-linux-gcc-13.2.0 ] ; then
# echo "tar xf ./mirror/x86_64-gcc-13.2.0-nolibc-riscv64-linux.tar.xz --strip-components=2 -C ./riscv-toolchain/"
# tar xf ./mirror/x86_64-gcc-13.2.0-nolibc-riscv64-linux.tar.xz --strip-components=2 -C ./riscv-toolchain/
#fi
#if [ -d ./hart-software-services/ ] ; then
# rm -rf ./hart-software-services/ || true
#fi
#echo "git clone -b ${HSS_BRANCH} ${HSS_REPO} ./hart-software-services/ --depth=${GIT_DEPTH}"
#git clone -b ${HSS_BRANCH} ${HSS_REPO} ./hart-software-services/ --depth=${GIT_DEPTH}
#if [ -d ./u-boot ] ; then
# rm -rf ./u-boot || true
#fi
#echo "git clone -b ${UBOOT_BRANCH} ${UBOOT_REPO} ./u-boot/ --depth=${GIT_DEPTH}"
#git clone -b ${UBOOT_BRANCH} ${UBOOT_REPO} ./u-boot/ --depth=${GIT_DEPTH}
if [ -d ./linux ] ; then
rm -rf ./linux || true
fi
echo "git clone -b ${LINUX_BRANCH} ${LINUX_REPO} ./linux/ --depth=${GIT_DEPTH}"
git clone -b ${LINUX_BRANCH} ${LINUX_REPO} ./linux/ --depth=${GIT_DEPTH}
#