diff options
author | Cem Keylan <cem@ckyln.com> | 2020-01-15 22:36:35 +0300 |
---|---|---|
committer | Cem Keylan <cem@ckyln.com> | 2020-01-15 22:36:35 +0300 |
commit | 051404c997c633388071203be5c24f28dfb9f14c (patch) | |
tree | 2b8e2a1cd5aeb0e94a784f34830c2e8f1540de1d /core/sinit | |
parent | 21fc7560eeaeb7ff0d25ef210570faf47c09357f (diff) | |
download | repository-051404c997c633388071203be5c24f28dfb9f14c.tar.gz |
sinit: removed ubase dependency, build respawn and halt onto sinit
Diffstat (limited to 'core/sinit')
-rwxr-xr-x | core/sinit/build | 15 | ||||
-rw-r--r-- | core/sinit/checksums | 5 | ||||
-rw-r--r-- | core/sinit/depends | 1 | ||||
-rw-r--r-- | core/sinit/files/sinit-launch-services.boot | 4 | ||||
-rw-r--r-- | core/sinit/files/sinit.post.shutdown | 4 | ||||
-rwxr-xr-x | core/sinit/post-install | 8 | ||||
-rw-r--r-- | core/sinit/sources | 3 | ||||
-rw-r--r-- | core/sinit/version | 2 |
8 files changed, 28 insertions, 14 deletions
diff --git a/core/sinit/build b/core/sinit/build index 182d70cf..4a3a1bf2 100755 --- a/core/sinit/build +++ b/core/sinit/build @@ -1,11 +1,24 @@ #!/bin/sh -e +ls +cp config.h sinit/config.h +cd sinit make CFLAGS="$CFLAGS -static" PREFIX=/usr DESTDIR="$1" install mv "$1/usr/bin/sinit" "$1/usr/bin/init" +cd .. install -Dm755 poweroff "$1/usr/bin/poweroff" install -Dm755 reboot "$1/usr/bin/reboot" install -Dm644 sinit-launch-services.boot "$1/etc/init/sinit-launch-services.boot" install -Dm644 sinit.post.shutdown "$1/etc/init/sinit.post.shutdown" -install -Dm644 sinit.pre.shutdown "$1/etc/init/sinit.pre.shutdown" + +# We are building ubase here so we don't need +# the full package + +cd ubase +make halt +make respawn + +install -Dm755 halt "$1/usr/bin/halt" +install -Dm755 respawn "$1/usr/bin/respawn" diff --git a/core/sinit/checksums b/core/sinit/checksums index c9d5e84e..5ce16c76 100644 --- a/core/sinit/checksums +++ b/core/sinit/checksums @@ -1,6 +1,7 @@ aaccd0515070545174bf962c462686e7719c02c68004bd0b350b98b4c78a90ba sinit-1.1.tar.gz +2fd1cd03b9ea9b0d08a523634be942177f1a370daa9a120e0279316003fb0ec1 b33bdaa.tar.gz 6f0f1a5f2f43b5bcfd4beaa93e1a49438d398cf758d7813bc6ba86b5156357a8 config.h f638aaa23383da584d3a56347a8e279abdc7c9c521661ef54a5bc8b955c5632b reboot d21a020d7cdb6a328962adac7cc1a8701a413c1dfabd40ac00bf7dc212fa29d1 poweroff -93f3b06594447598af207f44f2dde126f05724fde0a405bd15dd0f446ff26c6f sinit-launch-services.boot -a6952fbe916d2b9756b7dfc59bc5313a7d3749b22c59ab4db88ea76d4d76f097 sinit.post.shutdown +b8638d409b57b21d0deb11b6c0a5a870c0a6088d7733b205b0265bcc03d13486 sinit-launch-services.boot +913696a0bad385add0ea6207d5c6a8708fb4c74af7340715b12e98a094307e5c sinit.post.shutdown diff --git a/core/sinit/depends b/core/sinit/depends index 6ab349da..9a7ace20 100644 --- a/core/sinit/depends +++ b/core/sinit/depends @@ -1,2 +1 @@ carbs-init -ubase diff --git a/core/sinit/files/sinit-launch-services.boot b/core/sinit/files/sinit-launch-services.boot index 4d4fad6a..4cbb0570 100644 --- a/core/sinit/files/sinit-launch-services.boot +++ b/core/sinit/files/sinit-launch-services.boot @@ -2,12 +2,12 @@ sinit_run_getty() { for getty in 1 2 3 4 5 6; do - ubase-box respawn /sbin/getty 38400 tty${getty} 2>&1 & + respawn /sbin/getty 38400 tty${getty} 2>&1 & done } sinit_runit() { - ubase-box respawn /usr/bin/runsvdir -P /var/service & + respawn /usr/bin/runsvdir -P /var/service & } [ "$SINIT_ENABLE_GETTY" = 1 ] && sinit_run_getty diff --git a/core/sinit/files/sinit.post.shutdown b/core/sinit/files/sinit.post.shutdown index ade9958f..4f3c793b 100644 --- a/core/sinit/files/sinit.post.shutdown +++ b/core/sinit/files/sinit.post.shutdown @@ -6,11 +6,11 @@ if [ "$SINIT_SHUTDOWN_HOOKS" = 1 ]; then case "$1" in reboot) out "Requesting system reboot..." - /usr/bin/ubase-box halt -r + halt -r ;; *) out "Requesting system poweroff..." - /usr/bin/ubase-box halt -p + halt -p ;; esac fi diff --git a/core/sinit/post-install b/core/sinit/post-install index f9c906f2..11270008 100755 --- a/core/sinit/post-install +++ b/core/sinit/post-install @@ -2,10 +2,10 @@ grep -q SINIT_ /etc/init/rc.conf || cat <<EOF >> /etc/init/rc.conf -# Uncomment these to run the scripts for sinit -# SINIT_SHUTDOWN_HOOKS=1 -# SINIT_ENABLE_GETTY=1 -# SINIT_ENABLE_RUNIT=1 +# Comment these to run the scripts for sinit +SINIT_SHUTDOWN_HOOKS=1 +SINIT_ENABLE_GETTY=1 +SINIT_ENABLE_RUNIT=1 EOF cat <<EOF diff --git a/core/sinit/sources b/core/sinit/sources index 2d3a4d86..3630ef6e 100644 --- a/core/sinit/sources +++ b/core/sinit/sources @@ -1,4 +1,5 @@ -https://dl.carbslinux.org/distfiles/sinit-1.1.tar.gz +https://dl.carbslinux.org/distfiles/sinit-1.1.tar.gz sinit +https://github.com/michaelforney/ubase/archive/b33bdaa.tar.gz ubase files/config.h files/reboot files/poweroff diff --git a/core/sinit/version b/core/sinit/version index 08ad782f..ccfcfa47 100644 --- a/core/sinit/version +++ b/core/sinit/version @@ -1 +1 @@ -1.1 2 +1.1 3 |