Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.sbin/postinstall Install "etc/gpio.conf" if it is missing.



details:   https://anonhg.NetBSD.org/src/rev/f9e0623db5fb
branches:  trunk
changeset: 762031:f9e0623db5fb
user:      tron <tron%NetBSD.org@localhost>
date:      Sun Feb 13 20:25:35 2011 +0000

description:
Install "etc/gpio.conf" if it is missing.

diffstat:

 usr.sbin/postinstall/postinstall |  19 ++++++++++++++++++-
 1 files changed, 18 insertions(+), 1 deletions(-)

diffs (35 lines):

diff -r 7c92741981fb -r f9e0623db5fb usr.sbin/postinstall/postinstall
--- a/usr.sbin/postinstall/postinstall  Sun Feb 13 20:17:26 2011 +0000
+++ b/usr.sbin/postinstall/postinstall  Sun Feb 13 20:25:35 2011 +0000
@@ -1,6 +1,6 @@
 #!/bin/sh
 #
-# $NetBSD: postinstall,v 1.113 2011/02/13 20:17:26 tron Exp $
+# $NetBSD: postinstall,v 1.114 2011/02/13 20:25:35 tron Exp $
 #
 # Copyright (c) 2002-2008 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -819,6 +819,23 @@
 }
 
 #
+#      gpio
+#
+additem gpio "gpio configuration is up to date"
+do_gpio()
+{
+       [ -n "$1" ] || err 3 "USAGE: do_gpio fix|check"
+       op="$1"
+       failed=0
+
+       populate_dir "$op" true "${SRC_DIR}/etc" "${DEST_DIR}/etc" 644 \
+               gpio.conf
+       failed=$(( ${failed} + $? ))
+
+       return ${failed}
+}
+
+#
 #      hosts
 #
 additem hosts "/etc/hosts being up to date"



Home | Main Index | Thread Index | Old Index