diff options
author | Marvin Borner | 2019-06-29 17:54:50 +0200 |
---|---|---|
committer | Marvin Borner | 2019-06-29 17:54:50 +0200 |
commit | 46aa116c4f4ef5c2b55f36298b19aa9694ae5666 (patch) | |
tree | bc33d13fcb242d057345b56f5cad4291ac09d995 | |
parent | 37f5ca13e62d7424e018398cabc88c0ab715eeaa (diff) |
Improved installation process and network config
-rw-r--r-- | boot/grub/grub.cfg | 2 | ||||
-rw-r--r-- | bootstrap.sh | 7 | ||||
-rw-r--r-- | install.sh | 24 |
3 files changed, 21 insertions, 12 deletions
diff --git a/boot/grub/grub.cfg b/boot/grub/grub.cfg index 93df0e0..a14fb8c 100644 --- a/boot/grub/grub.cfg +++ b/boot/grub/grub.cfg @@ -4,5 +4,5 @@ set timeout=5 set root=(hd0,1) menuentry "Melvix 0.1a" { -linux /boot/vmlinuz root=/dev/sdb1 ro quiet +linux /boot/vmlinuz root=/dev/sda1 ro quiet } diff --git a/bootstrap.sh b/bootstrap.sh index 3904dfb..a236bd1 100644 --- a/bootstrap.sh +++ b/bootstrap.sh @@ -23,6 +23,7 @@ curl -sSL "http://ftp.gnu.org/gnu/mpc/mpc-1.1.0.tar.gz" | tar xz curl -sSL "http://ftp.gnu.org/gnu/glibc/glibc-2.29.tar.xz" | tar xJ curl -sSL "http://ftp.gnu.org/gnu/mpfr/mpfr-4.0.2.tar.xz" | tar xJ curl -sSL "https://www.zlib.net/zlib-1.2.11.tar.xz" | tar xJ +curl -sSl "https://roy.marples.name/downloads/dhcpcd/dhcpcd-7.2.3.tar.xz" | tar xJ cd ${MELVIX} echo -en "\r Initializing filesystem structure" @@ -181,6 +182,12 @@ ln -sf ../../lib/libz.so.1 ${MELVIX}/usr/lib/libz.so ln -sf ../../lib/libz.so.1 ${MELVIX}/usr/lib/libz.so.1 ln -sf ../lib/libz.so.1 ${MELVIX}/lib64/libz.so.1 +echo -en "\r Building dhcpcd" +cd ${MELVIX}/sources/dhcpcd-7.2.3 +./configure --prefix=/usr --sbindir=/sbin --sysconfdir=/etc --dbdir=/var/lib/dhcpcd --libexecdir=/usr/lib/dhcpcd &> /dev/null +make &> /dev/null +make DESTDIR=${MELVIX}/ install &> /dev/null + # Cleanup echo -en "\r Cleaning up and backing up current state" cp -rf ${MELVIX}/ ${MELVIX}-copy @@ -1,6 +1,6 @@ #!/usr/bin/env bash -export source=$(pwd) +export SOURCE=$(pwd) sudo useradd -m melvix sudo mkdir -p /home/melvix/os @@ -11,17 +11,19 @@ sudo cp bootstrap.sh /home/melvix tput civis while :;do for s in / - \\ \|; do printf "\r$s";sleep .1;done;done & trap "kill $!" EXIT -sudo -i -u melvix bash bootstrap.sh ${source} +sudo -i -u melvix bash bootstrap.sh ${SOURCE} kill $! && trap " " EXIT tput cnorm export MELVIX=/home/melvix/os -sudo find ${MELVIX}-copy/{,usr/}{bin,lib,sbin} -type f -exec sudo strip --strip-debug '{}' ';' -sudo find ${MELVIX}-copy/{,usr/}lib64 -type f -exec sudo strip --strip-debug '{}' ';' -sudo chown -R root:root ${MELVIX}-copy -sudo chgrp 13 ${MELVIX}-copy/var/run/utmp ${MELVIX}-copy/var/log/lastlog -sudo mknod -m 0666 ${MELVIX}-copy/dev/null c 1 3 -sudo mknod -m 0600 ${MELVIX}-copy/dev/console c 5 1 -sudo chmod 4755 ${MELVIX}-copy/bin/busybox - -sudo tar cfJ ${source}/melvix-build.tar.xz ${MELVIX}-copy/*
\ No newline at end of file +sudo -i bash << EOF +find ${MELVIX}-copy/{,usr/}{bin,lib,sbin} -type f -exec sudo strip --strip-debug '{}' ';' &> /dev/null +find ${MELVIX}-copy/{,usr/}lib64 -type f -exec sudo strip --strip-debug '{}' ';' &> /dev/null +chown -R root:root ${MELVIX}-copy +chgrp 13 ${MELVIX}-copy/var/run/utmp ${MELVIX}-copy/var/log/lastlog &> /dev/null +mknod -m 0666 ${MELVIX}-copy/dev/null c 1 3 &> /dev/null +mknod -m 0600 ${MELVIX}-copy/dev/console c 5 1 &> /dev/null +chmod 4755 ${MELVIX}-copy/bin/busybox +cd ${MELVIX}-copy +tar cfJ ${SOURCE}/melvix-build.tar.xz * &> /dev/null +EOF |