Add tool for creating Everest images

This commit is contained in:
lw-everestlinux 2022-12-01 09:29:12 -05:00
parent 3b4c6f33cf
commit 346b351ad0
2 changed files with 50 additions and 0 deletions

View 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
}

View File