iglunix-autobuild/chroot_fetch

69 lines
1.4 KiB
Text
Raw Normal View History

2021-02-04 16:58:42 +00:00
#!/bin/bash
#-----
# Packages
#-----
echo "------------------"
echo "Primary packages"
echo "------------------"
packages=(mksh bmake gmake busybox toybox libressl cmake curl rsync linux flex byacc om4 zlib expat samurai libffi python ca-certificates)
root=$(pwd)/root/
for pkg in ${packages[@]};do
echo "$pkg"
2021-02-06 12:46:14 +00:00
source ${root}/iglunix/pkgs/${pkg}/build.sh
cd ${root}/iglunix/pkgs/${pkg}/
2021-02-04 16:58:42 +00:00
#Only needed if you want to clean
#sudo rm -rf src
if test -d "src"; then
echo "Already got the source for ${pkg}?! No need to download.."
else
rm src 2> /dev/null
#src could be a file (file != dir)
mkdir src
cd src
fetch
fi
done
#-----
# tmp Packages
#-----
echo "------------------"
echo "Temporary packages"
echo "------------------"
2021-02-06 12:46:14 +00:00
mkdir ${root}/iglunix/tmp_pkgs/
2021-02-04 16:58:42 +00:00
#echo "ibara baseutils"
2021-02-06 12:46:14 +00:00
#cd ${root}/iglunix/tmp_pkgs/
2021-02-04 16:58:42 +00:00
#git clone https://github.com/ibara/baseutils.git
echo "------------------------------------"
echo " shell scripts/single files"
echo "------------------------------------"
cp ${root}/../dont_use_here/inside_chroot ${root}
cp ${root}/../dont_use_here/linux_header_only_patch ${root}
cp ${root}/../dont_use_here/inittab ${root}/etc/inittab
mkdir ${root}/etc
mkdir ${root}/etc/profile.d
cp ${root}/../dont_use_here/profile ${root}/etc/profile
2021-02-21 14:30:04 +00:00
cat << EOF > ${root}/login_shell
2021-02-21 14:39:18 +00:00
exec -a "-sh" /bin/sh
2021-02-21 14:30:04 +00:00
EOF
2021-02-04 16:58:42 +00:00
echo "---------------------"
echo "finished chroot_fetch"
echo "---------------------"