summaryrefslogtreecommitdiff
path: root/usr/src
diff options
context:
space:
mode:
authorguoqing zhu - Sun Microsystems - Beijing China <Guoqing.Zhu@Sun.COM>2009-10-24 16:23:18 +0800
committerguoqing zhu - Sun Microsystems - Beijing China <Guoqing.Zhu@Sun.COM>2009-10-24 16:23:18 +0800
commitcfded042ba3325f6b90f025ca176ab143a6dc075 (patch)
tree9b4e32f99c31056ed4e5d322f24d00efdd0c4753 /usr/src
parent71be8d8f808a6f8b1a1bbb502fb01c7ccdb8512d (diff)
downloadillumos-joyent-cfded042ba3325f6b90f025ca176ab143a6dc075.tar.gz
6887730 'kernel/drv/usbser_edge.conf' has incorrect e/none combination of ftype/class assigned
Diffstat (limited to 'usr/src')
-rw-r--r--usr/src/pkgdefs/SUNWuedg/Makefile5
-rw-r--r--usr/src/pkgdefs/SUNWuedg/pkginfo.tmpl5
-rw-r--r--usr/src/pkgdefs/SUNWuedg/prototype_com3
-rw-r--r--usr/src/pkgdefs/common_files/i.edgeconf53
4 files changed, 60 insertions, 6 deletions
diff --git a/usr/src/pkgdefs/SUNWuedg/Makefile b/usr/src/pkgdefs/SUNWuedg/Makefile
index 36e5b5847c..1f29287edb 100644
--- a/usr/src/pkgdefs/SUNWuedg/Makefile
+++ b/usr/src/pkgdefs/SUNWuedg/Makefile
@@ -19,16 +19,17 @@
# CDDL HEADER END
#
#
-# Copyright 2008 Sun Microsystems, Inc. All rights reserved.
+# Copyright 2009 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
-#ident "%Z%%M% %I% %E% SMI"
include ../Makefile.com
LICENSEFILES += $(OSBL)
CDDL=
+DATAFILES += i.edgeconf
+
.KEEP_STATE:
all: $(FILES) depend postinstall preremove
diff --git a/usr/src/pkgdefs/SUNWuedg/pkginfo.tmpl b/usr/src/pkgdefs/SUNWuedg/pkginfo.tmpl
index 838b7b46d3..438ec4d1fa 100644
--- a/usr/src/pkgdefs/SUNWuedg/pkginfo.tmpl
+++ b/usr/src/pkgdefs/SUNWuedg/pkginfo.tmpl
@@ -20,10 +20,9 @@
#
#
-# Copyright 2006 Sun Microsystems, Inc. All rights reserved.
+# Copyright 2009 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
-# ident "%Z%%M% %I% %E% SMI"
#
#
@@ -37,7 +36,7 @@ ARCH="ISA"
CATEGORY="system"
BASEDIR=/
SUNW_PKGTYPE="root"
-CLASSES="none"
+CLASSES="none edgeconf"
DESC="USB Digi Edgeport serial driver"
SUNW_PRODNAME="SunOS"
SUNW_PRODVERS="RELEASE/VERSION"
diff --git a/usr/src/pkgdefs/SUNWuedg/prototype_com b/usr/src/pkgdefs/SUNWuedg/prototype_com
index 458b1aedc4..2fc4ba7cb9 100644
--- a/usr/src/pkgdefs/SUNWuedg/prototype_com
+++ b/usr/src/pkgdefs/SUNWuedg/prototype_com
@@ -42,6 +42,7 @@ i depend
i pkginfo
i postinstall
i preremove
+i i.edgeconf
d none kernel 0755 root sys
d none kernel/drv 0755 root sys
-e none kernel/drv/usbser_edge.conf 0644 root sys
+e edgeconf kernel/drv/usbser_edge.conf 0644 root sys
diff --git a/usr/src/pkgdefs/common_files/i.edgeconf b/usr/src/pkgdefs/common_files/i.edgeconf
new file mode 100644
index 0000000000..8bd7c85d30
--- /dev/null
+++ b/usr/src/pkgdefs/common_files/i.edgeconf
@@ -0,0 +1,53 @@
+#!/bin/sh
+#
+# CDDL HEADER START
+#
+# The contents of this file are subject to the terms of the
+# Common Development and Distribution License (the "License").
+# You may not use this file except in compliance with the License.
+#
+# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
+# or http://www.opensolaris.org/os/licensing.
+# See the License for the specific language governing permissions
+# and limitations under the License.
+#
+# When distributing Covered Code, include this CDDL HEADER in each
+# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
+# If applicable, add the following below this CDDL HEADER, with the
+# fields enclosed by brackets "[]" replaced with your own identifying
+# information: Portions Copyright [yyyy] [name of copyright owner]
+#
+# CDDL HEADER END
+#
+#
+#
+# Copyright 2009 Sun Microsystems, Inc. All rights reserved.
+# Use is subject to license terms.
+#
+# Update the usbser_edge.conf file. The distributed usbser_edge.conf consists
+# only of comments, ending in a marker line. To update, the new file
+# (all comments) is appended by any lines in the user's old file that
+# appear after the marker.
+#
+
+PATH="/usr/bin:/usr/sbin:${PATH}"
+export PATH
+TMP_FILE=/tmp/usbser_edge.$$
+export TMP_FILE
+
+while read src dest
+do
+ if [ ! -f $dest ] ; then
+ cp $src $dest
+ else
+ # copy everything after marker line to a tmp file
+ MARKER="# DO NOT MODIFY OR DELETE THIS LINE -- CUSTOMIZED CONFIGURATION BELLOW #"
+ sed -e "1,/^$MARKER$/d" $dest > $TMP_FILE
+
+ # combine new file with saved lines from user's old file
+ cat $src $TMP_FILE > $dest
+ rm $TMP_FILE
+ fi
+done
+
+exit 0