Add tool for creating Everest images
This commit is contained in:
parent
3b4c6f33cf
commit
346b351ad0
50
src/glacier-mkimg/glacier-mkimg
Normal file
50
src/glacier-mkimg/glacier-mkimg
Normal file
@ -0,0 +1,50 @@
|
||||
#!/bin/sh
|
||||
# Tool for creating Everest Linux images
|
||||
|
||||
mkskel() {
|
||||
printf ">> Creating build directory at /mnt/everest\n"
|
||||
mkdir -v /mnt/everest
|
||||
printf ">> Creating toolchain directories at /opt/everest\n"
|
||||
mkdir -v /opt/everest
|
||||
mkdir -v /opt/everest/toolchain
|
||||
mkdir -v /opt/everest/sources
|
||||
printf ">> Creating filesystem skeleton at /mnt/everest\n"
|
||||
mkdir -pv /mnt/everest/{bin,boot,dev,etc,home,lib/{firmware,modules}}
|
||||
mkdir -pv /mnt/everest/{mnt,opt,proc,sbin,srv,sys}
|
||||
mkdir -pv /mnt/everest/var/{cache,lib,local,lock,log,opt,run,spool}
|
||||
install -dv -m 0750 /mnt/everest/root
|
||||
install -dv -m 1777 /mnt/everest/{var/,}tmp
|
||||
mkdir -pv /mnt/everest/usr/{,local/}{bin,include,lib,sbin,share,src}
|
||||
printf "=============== SUMMARY ===============\n"
|
||||
printf "Target directory: /mnt/everest\n"
|
||||
printf "Toolchain directory: /opt/everest/toolchain\n"
|
||||
printf "Sources directory: /opt/everest/sources\n"
|
||||
sleep 2
|
||||
}
|
||||
|
||||
get_sources() {
|
||||
printf ">> Downloading the following packages:\n"
|
||||
printf "- GNU Binutils\n"
|
||||
printf "- GNU GCC\n"
|
||||
printf "- GNU GMP\n"
|
||||
printf "- GNU MPC\n"
|
||||
printf "- GNU MPFR\n"
|
||||
printf "- musl\n"
|
||||
printf "- Busybox\n"
|
||||
printf "- iana-etc\n"
|
||||
printf "- everest-bootscripts\n"
|
||||
printf "- everest-distfiles\n"
|
||||
printf "- GNU make\n"
|
||||
printf "- Python\n"
|
||||
printf "- glacier\n"
|
||||
sleep 2
|
||||
|
||||
printf ">> Downloading packages...\n"
|
||||
cd /opt/everest/sources
|
||||
wget -i sources-list
|
||||
|
||||
printf ">> Finished downloading packages.\n"
|
||||
sleep 2
|
||||
}
|
||||
|
||||
|
0
src/glacier-mkimg/sources-list
Normal file
0
src/glacier-mkimg/sources-list
Normal file
Loading…
Reference in New Issue
Block a user