From d1e063beb43e595680c65e3804d1f8ddff53373b Mon Sep 17 00:00:00 2001 From: Guido Guenther Date: Sat, 18 Nov 2006 23:48:07 +0100 Subject: Imported Debian version 0.3.8.8 --- debian/postinst | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 debian/postinst (limited to 'debian/postinst') diff --git a/debian/postinst b/debian/postinst new file mode 100644 index 0000000..71e956d --- /dev/null +++ b/debian/postinst @@ -0,0 +1,41 @@ +#!/bin/bash +# $Id: postinst,v 1.1 2004/11/29 10:39:38 ladis Exp $ + +set -e + +# Source debconf library. +. /usr/share/debconf/confmodule + +case "$1" in + configure) + db_get arcboot/boot_device || true + + if [ ! -f /etc/arcboot.conf ]; then + # create /etc/arcboot.conf + ROOTDEVICE=`mount | grep -s '[[:space:]]/[[:space:]]' | cut -d' ' -f 1` + +cat << EOF > /etc/arcboot.conf +# arcboot.conf +# +label=linux + image=/vmlinux + append="root=$ROOTDEVICE" +EOF + fi + /usr/sbin/arcboot $RET + + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 0 + ;; +esac + +#DEBHELPER# + +exit 0 -- cgit v1.2.3