Merge pull request #110 from bauen1/misc-changes

Misc changes - added deps for some bundles, autorun enhancements, host resolution, code refactoring.
This commit is contained in:
Ivan Davidov 2017-11-18 22:59:03 +02:00 committed by GitHub
commit 23f34f3941
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
23 changed files with 164 additions and 143 deletions

View File

@ -248,6 +248,7 @@ COPY_SOURCE_ISO=true
# fio - I/O load generator. # fio - I/O load generator.
# java - installs Oracle's JRE or JDK. Manual preparations are required. # java - installs Oracle's JRE or JDK. Manual preparations are required.
# kbd - keyboard utilities # kbd - keyboard utilities
# kexec-tools - execute another kernel from userspace
# libevent - event notification library. # libevent - event notification library.
# links - text browser for the web. # links - text browser for the web.
# lua - scripting language. # lua - scripting language.

View File

@ -1,12 +1,11 @@
#!/bin/sh #!/bin/sh
set -e
echo "*** CLEAN BEGIN ***" echo "*** CLEAN BEGIN ***"
echo "Cleaning up the main work area. This may take a while..." echo "Cleaning up the main work area. This may take a while..."
rm -rf work rm -rf work
mkdir work mkdir work
# -p stops errors if the directory already exists
mkdir -p source mkdir -p source
echo "*** CLEAN END ***" echo "*** CLEAN END ***"

View File

@ -1,4 +1,5 @@
#!/bin/sh #!/bin/sh
set -e
echo "*** PREPARE SRC BEGIN ***" echo "*** PREPARE SRC BEGIN ***"

View File

@ -1,4 +1,5 @@
#!/bin/sh #!/bin/sh
set -e
echo "*** GENERATE ROOTFS BEGIN ***" echo "*** GENERATE ROOTFS BEGIN ***"

View File

@ -1,4 +1,5 @@
#!/bin/sh #!/bin/sh
set -e
echo "*** PACK ROOTFS BEGIN ***" echo "*** PACK ROOTFS BEGIN ***"

View File

@ -1,4 +1,5 @@
#!/bin/sh #!/bin/sh
set -e
echo "*** GET SYSLINUX BEGIN ***" echo "*** GET SYSLINUX BEGIN ***"

View File

@ -69,6 +69,8 @@ Currently available overlay bundles:
callback function when a specific event occurs on a file callback function when a specific event occurs on a file
descriptor or after a timeout has been reached. descriptor or after a timeout has been reached.
* kexec-tools - Kexec tools, can be used to boot another kernel from userspace
* Links - Text based browser. Requires ~1MB additional space. Use the * Links - Text based browser. Requires ~1MB additional space. Use the
"links" command to activate the browser. "links" command to activate the browser.

View File

@ -13,6 +13,8 @@ DESTDIR="$MAIN_SRC_DIR/work/src/minimal_overlay/rootfs"
mkdir -p "$DESTDIR" mkdir -p "$DESTDIR"
install -d -m755 "$DESTDIR/etc" install -d -m755 "$DESTDIR/etc"
install -m644 "$SRC_DIR/hosts" "$DESTDIR/etc/hosts"
install -m644 "$SRC_DIR/nsswitch.conf" "$DESTDIR/etc/nsswitch.conf"
install -m644 "$SRC_DIR/resolv.conf" "$DESTDIR/etc/resolv.conf" install -m644 "$SRC_DIR/resolv.conf" "$DESTDIR/etc/resolv.conf"
install -d -m755 "$DESTDIR/etc/autorun" install -d -m755 "$DESTDIR/etc/autorun"
install -m755 "$SRC_DIR/01_network.sh" "$DESTDIR/etc/autorun/01_network.sh" install -m755 "$SRC_DIR/01_network.sh" "$DESTDIR/etc/autorun/01_network.sh"
@ -22,6 +24,7 @@ install -m755 "$SRC_DIR/05_rc.dhcp" "$DESTDIR/etc/05_rc.dhcp"
install -d -m755 "$DESTDIR/lib" install -d -m755 "$DESTDIR/lib"
install -m755 "$SYSROOT/lib/libresolv.so.2" "$DESTDIR/lib/libresolv.so.2" install -m755 "$SYSROOT/lib/libresolv.so.2" "$DESTDIR/lib/libresolv.so.2"
install -m755 "$SYSROOT/lib/libnss_dns.so.2" "$DESTDIR/lib/libnss_dns.so.2" install -m755 "$SYSROOT/lib/libnss_dns.so.2" "$DESTDIR/lib/libnss_dns.so.2"
install -m755 "$SYSROOT/lib/libnss_files.so.2" "$DESTDIR/lib/libnss_files.so.2"
strip -g "$DESTDIR/lib/*" 2>/dev/null strip -g "$DESTDIR/lib/*" 2>/dev/null
echo "dhcp scripts and libraries have been installed" echo "dhcp scripts and libraries have been installed"

View File

@ -0,0 +1,5 @@
# /etc/hosts
127.0.0.1 localhost
# ipv6
::1 localhost ipv6-localhost

View File

@ -0,0 +1 @@
hosts: files dns

View File

@ -0,0 +1 @@
ncurses

View File

@ -0,0 +1 @@
glibc_full

View File

@ -0,0 +1 @@
ncurses

View File

@ -24,7 +24,7 @@ install -m644 "$SRC_DIR/index.html" "$DESTDIR/srv/www/index.html"
install -m644 "$SRC_DIR/favicon.ico" "$DESTDIR/srv/www/favicon.ico" install -m644 "$SRC_DIR/favicon.ico" "$DESTDIR/srv/www/favicon.ico"
install -d -m755 "$DESTDIR/etc" install -d -m755 "$DESTDIR/etc"
install -d -m755 "$DESTDIR/etc/autorun" install -d -m755 "$DESTDIR/etc/autorun"
install -m755 "$SRC_DIR/nweb.sh" "$DESTDIR/etc/autorun/90_nweb.sh" install -m755 "$SRC_DIR/90_nweb.sh" "$DESTDIR/etc/autorun/90_nweb.sh"
echo "nweb has been installed." echo "nweb has been installed."
echo "It will be autostarted on boot." echo "It will be autostarted on boot."

View File

@ -0,0 +1 @@
ncurses

View File

@ -1,4 +1,4 @@
#!/bin/bash #!/bin/sh
SRC_DIR=$(pwd) SRC_DIR=$(pwd)

View File

@ -30,8 +30,10 @@ echo -e "Welcome to \\e[1mMinimal \\e[32mLinux \\e[31mLive\\e[0m (/sbin/init)"
if [ -d /etc/autorun ] ; then if [ -d /etc/autorun ] ; then
for AUTOSCRIPT in /etc/autorun/* for AUTOSCRIPT in /etc/autorun/*
do do
if [ -f "$AUTOSCRIPT" ] && [ -x "$AUTOSCRIPT" ]; then
echo -e "Executing \\e[32m$AUTOSCRIPT\\e[0m in subshell." echo -e "Executing \\e[32m$AUTOSCRIPT\\e[0m in subshell."
sh $AUTOSCRIPT $AUTOSCRIPT
fi
done done
fi fi