From 4944968bc2fe4eb5573aba89ea074dcfba0dcb12 Mon Sep 17 00:00:00 2001 From: Samuel Thibault Date: Thu, 8 Feb 2024 22:02:58 +0100 Subject: runsystem: do not require bash So that people can install just dash. --- daemons/runsystem.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'daemons/runsystem.sh') diff --git a/daemons/runsystem.sh b/daemons/runsystem.sh index 5d0ad01f..aae584c9 100644 --- a/daemons/runsystem.sh +++ b/daemons/runsystem.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/sh # # This program is run by /hurd/init at boot time after the essential # servers are up. It does some initialization of its own and then @@ -32,18 +32,18 @@ init=/hurd/init # If we get a SIGLOST, attempt to reopen the console in case # our console ports were revoked. This lets us print messages. -function reopen_console () +reopen_console () { exec 1>/dev/console 2>&1 || exit 3 } -trap 'reopen_console' SIGLOST +trap 'reopen_console' 32 # SIGLOST = server died on GNU # Call this when we are losing badly enough that we want to punt normal # startup entirely. We exec a single-user shell, so we will not come back # here. The only way to get to multi-user from that shell will be # explicitly exec this script or something like that. -function singleuser() +singleuser () { test $# -eq 0 || echo "$0: $*" for try in ${fallback_shells}; do @@ -120,5 +120,5 @@ esac # This is necessary to make stat / return the correct device ids. fsysopts / --update --readonly -# Finally, start the actual init. +# Finally, start the actual SysV init. exec ${init} ${single} -a -- cgit v1.2.3