18444 lint libraries and lintlibraries osol_167
authorDavid Powell <david.e.powell@oracle.com>
Sat, 28 May 2011 17:58:14 -0700
changeset 711 1ffc0db7d2e5
parent 710 beb915128edf
child 712 9c5898982b0e
18444 lint libraries and lintlibraries
usr/src/Makefile.env
usr/src/Makefile.targ
usr/src/doc/rad-dev/Makefile
usr/src/java/Makefile
usr/src/lib/Makefile
usr/src/lib/Makefile.com
usr/src/lib/Makefile.env
usr/src/lib/Makefile.lib
usr/src/lib/Makefile.targ
usr/src/lib/conv_test/Makefile
usr/src/lib/conv_test/Makefile.com
usr/src/lib/libUnixDomainSocket_jni/Makefile
usr/src/lib/libUnixDomainSocket_jni/Makefile.com
usr/src/lib/libUnixDomainSocket_jni/Makefile.env
usr/src/lib/libUnixDomainSocket_jni/UnixDomainSocket.c
usr/src/lib/libUnixDomainSocket_jni/UnixSocket.c
usr/src/lib/libUnixDomainSocket_jni/UnixSocketServer.c
usr/src/lib/libadr/Makefile
usr/src/lib/libadr/Makefile.com
usr/src/lib/libadr/common/adr.c
usr/src/lib/libadr/common/adr_name.c
usr/src/lib/libadr/common/adr_stream.c
usr/src/lib/libadr/common/adr_typeset.c
usr/src/lib/libadr/common/llib-ladr
usr/src/lib/libadr/common/mapfile-vers
usr/src/lib/libadr_mdb/Makefile
usr/src/lib/libadr_mdb/Makefile.com
usr/src/lib/libadr_mdb/common/adr_object.c
usr/src/lib/libjniutil/Makefile
usr/src/lib/libjniutil/Makefile.com
usr/src/lib/libjniutil/llib-ljniutil
usr/src/lib/libradproto/Makefile
usr/src/lib/libradproto/Makefile.com
usr/src/lib/libradproto/common/llib-lradproto
usr/src/lib/libradproto/common/mapfile-vers
usr/src/lib/libradproto/common/radclient.c
usr/src/lib/libradproto/common/radproto_adr.c
usr/src/pkg/manifests/system-management-rad.p5m
usr/src/test/c/Makefile.com
usr/src/test/c/common/Makefile
usr/src/test/java/Makefile
--- a/usr/src/Makefile.env	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/Makefile.env	Sat May 28 17:58:14 2011 -0700
@@ -77,7 +77,7 @@
 DIRMODE = 755
 INS.dir = $(INS) -s -d -m $(DIRMODE) $@
 INS.file = $(INS) -s -d -m $(DIRMODE) $(@D); \
-	$(RM) -- $@; $(INS) -s -m $(FILEMODE) -f $(@D) $(@F)
+	$(RM) -- $@; $(INS) -s -m $(FILEMODE) -f $(@D) $<
 INS.pyfile = $(INS.file); $(TOUCH) -r $< $@
 
 # Tools and dependencies used at build time
@@ -90,6 +90,7 @@
 GTAR = /usr/sfw/bin/gtar
 HEAD = /usr/bin/head
 INS = /usr/sbin/install
+LN = /usr/bin/ln
 LS = /usr/bin/ls
 MKDIR = /usr/bin/mkdir
 PKG = /usr/bin/pkg
--- a/usr/src/Makefile.targ	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/Makefile.targ	Sat May 28 17:58:14 2011 -0700
@@ -20,7 +20,7 @@
 #
 
 #
-# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
 #
@@ -38,7 +38,7 @@
 all install lint: $(SUBDIRS)
 
 # Add to above dependency
-install lint: all
+install: all
 
 $(DEPENDENCY_JARS):
 	cd $(@D); $(MAKE) $(@F)
--- a/usr/src/doc/rad-dev/Makefile	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/doc/rad-dev/Makefile	Sat May 28 17:58:14 2011 -0700
@@ -20,7 +20,7 @@
 #
 
 #
-# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
 include ../Makefile.doc
@@ -63,7 +63,7 @@
 # lint produces many benign errors due to older DocBook schemata not
 # allowing for use of XInclude.  The rest are meaningful.
 
-lint:	examples
+doclint: examples
 	$(XMLLINT) $(SRCS)
 
 include $(SRC)/Makefile.targ
--- a/usr/src/java/Makefile	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/java/Makefile	Sat May 28 17:58:14 2011 -0700
@@ -20,12 +20,14 @@
 #
 
 #
-# Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2009, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
 MSUBDIRS = scf vpanels
 ASUBDIRS = lib util sleeklock adr rad
 
+lint:
+
 vpanels: lib scf util adr rad sleeklock
 
 adr: util
--- a/usr/src/lib/Makefile	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/Makefile	Sat May 28 17:58:14 2011 -0700
@@ -20,12 +20,14 @@
 #
 
 #
-# Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2009, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
-include $(SRC)/Makefile.env
+include Makefile.env
 
 libUnixDomainSocket_jni: libjniutil
-libadr_mdb: libadr
+libadr_mdb libradproto: libadr
 
-include $(SRC)/Makefile.targ
+install: $(ROOTLIBLINK32) $(ROOTLIBLINK64)
+
+include Makefile.targ
--- a/usr/src/lib/Makefile.com	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/Makefile.com	Sat May 28 17:58:14 2011 -0700
@@ -20,9 +20,37 @@
 #
 
 #
-# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
 include "Makefile.env"
 
+MAPFILES_i386 = /usr/lib/ld/map.noexdata
+MAPFILES_sparc =
+MAPFILES = $(MAPFILES_$(ISA)) /usr/lib/ld/map.pagealign
+
 CFLAGS += $(CCARCH) -Kpic -g -mt -errwarn=%all
+MAPOPTS = $(MAPFILES:%=-M%)
+LDFLAGS = $(MAPOPTS) -Wl,-zdefs -lc
+
+LIBNAME = $(LIBRARY:lib%.a=%)
+DYNLIB = $(LIBRARY:.a=.so$(VERS))
+SOLIB = $(LIBRARY:.a=.so)
+
+LINTLIB = llib-l$(LIBNAME).ln
+LINTSRC = $(LINTLIB:%.ln=%)
+LINTOUT = lint.out
+
+LINTCHECKFLAGS = -m -erroff=E_NAME_DEF_NOT_USED2
+LINTCHECKFLAGS += -erroff=E_NAME_DECL_NOT_USED_DEF2
+
+LINTFLAGSBASE = -uaxm $(ALWAYS_LINT_DEFS)
+LINTFLAGS32 = $(LINTFLAGSBASE)
+LINTFLAGS64 = -m64 $(LINTFLAGSBASE)
+LINTFLAGS = $(LINTFLAGS$(LLINK))
+
+ROOTLIBDIR=$(ROOTLIBDIR$(LLINK))
+
+ROOTLINT=$(LINTSRC:%=$(ROOTLINTDIR)/%)
+ROOTLIBS=$(LIBS:%=$(ROOTLIBDIR)/%)
+ROOTHDRS=$(HDRS:%=$(ROOTHDRDIR)/%)
--- a/usr/src/lib/Makefile.env	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/Makefile.env	Sat May 28 17:58:14 2011 -0700
@@ -20,9 +20,26 @@
 #
 
 #
-# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
 include $(SRC)/Makefile.env
 
+LIBDIR64_i386=amd64
+LIBDIR64_sparc=sparcv9
+LIBDIR64=$(LIBDIR64_$(ISA))
+
+ROOTLIBBASE=$(PROTO_LIB)
+
+ROOTLIBDIR32=$(ROOTLIBBASE)
+ROOTLIBDIR64=$(ROOTLIBBASE)/$(LIBDIR64)
+
+ROOTLIBLINK32=$(ROOTLIBBASE)/32
+ROOTLIBTGT32=.
+
+ROOTLIBLINK64=$(ROOTLIBBASE)/64
+ROOTLIBTGT64=$(LIBDIR64)
+
+ROOTLINTDIR=$(ROOTLIBBASE)
+
 ROOTHDRDIR=$(ROOT)/usr/include
--- a/usr/src/lib/Makefile.lib	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/Makefile.lib	Sat May 28 17:58:14 2011 -0700
@@ -20,10 +20,10 @@
 #
 
 #
-# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
-include $(SRC)/Makefile.targ
+include "Makefile.targ"
 
 HEADERS=$(HDRS:%=$(HDRDIR)/%)
 
@@ -32,4 +32,26 @@
 	mkdir -p $(ROOTHDRDIR)
 	install -f $(ROOTHDRDIR) -m 644 -s $<
 
-install_h: $(HDRS:%=$(ROOTHDRDIR)/%)
+install_h: $(ROOTHDRS)
+
+lintcheck: $$(SRCS)
+	$(LINT.c) $(LINTCHECKFLAGS) $(SRCS) $(LDLIBS)
+
+$(LINTLIB): $$(SRCS)
+	$(LINT.c) -mnuvxy -o $(LIBNAME) $(SRCS) > $(LINTOUT) 2>&1
+
+$(ROOTLINTDIR)/%: $(SRCDIR)/%
+	$(INS.file)
+
+$(ROOTLIBDIR)/%: %
+	$(INS.file)
+
+$(DYNLIB): $(OBJS) $(MAPFILES)
+	$(CC) $(CCARCH) -G -h $@ -o $@ $(OBJS) $(LDFLAGS) $(LDLIBS)
+
+$(ROOTLIBDIR)/$(SOLIB): $(ROOTLIBDIR)
+	$(RM) $@
+	$(LN) -fs $(DYNLIB) $@
+
+%.o: $(SRCDIR)/%.c
+	$(COMPILE.c) $(OUTPUT_OPTION) $<
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/usr/src/lib/Makefile.targ	Sat May 28 17:58:14 2011 -0700
@@ -0,0 +1,37 @@
+#
+# 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 (c) 2011, Oracle and/or its affiliates. All rights reserved.
+#
+
+include $(SRC)/Makefile.targ
+
+$(ROOTLIBDIR32) $(ROOTLIBDIR64):
+	$(INS.dir)
+
+$(ROOTLIBLINK32): $(ROOTLIBDIR32)
+	$(RM) $@
+	ln -fs $(ROOTLIBTGT32) $@
+
+$(ROOTLIBLINK64): $(ROOTLIBDIR32)
+	$(RM) $@
+	ln -fs $(ROOTLIBTGT64) $@
--- a/usr/src/lib/conv_test/Makefile	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/conv_test/Makefile	Sat May 28 17:58:14 2011 -0700
@@ -23,6 +23,5 @@
 # Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
-include ../Makefile.env
 include ../Makefile.subdirs
 include ../Makefile.lib
--- a/usr/src/lib/conv_test/Makefile.com	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/conv_test/Makefile.com	Sat May 28 17:58:14 2011 -0700
@@ -23,33 +23,28 @@
 # Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
+LIBRARY = rad_conv_test.a
+VERS =
+
 include "../Makefile.com"
 
-TARG = rad_conv_test.so
+ROOTLIBBASE=$(PROTO_LIB)/security
+SOLIB=__none__
+
 OBJS = conv_test.o
 
 SRCDIR=../common
 SRCS=$(OBJS:%.o=$(SRCDIR)/%.c)
-CPPFLAGS = -I$(ROOT)/usr/include
-LFLAGS = -Wl,-zdefs -lc -lpam
-LPATH = $(ROOT)/usr/lib/security/$(LDIR)
+LDFLAGS += -lpam
+LIBS = $(DYNLIB)
 
 CLEAN_FILES += $(OBJS)
-CLOBBER_FILES += $(TARG)
-
-all: $(TARG)
+CLOBBER_FILES += $(DYNLIB)
 
-install: $(TARG)
-	mkdir -p $(LPATH)
-	/usr/sbin/install -f $(LPATH) -m 755 -s $(TARG)
+all: $(DYNLIB)
 
-$(TARG): $(OBJS)
-	$(CC) $(CCARCH) -G -h $@ -o $@ $(OBJS) $(LFLAGS) $(LDLIBS)
+lint: lintcheck
 
-%.o: $(SRCDIR)/%.c
-	$(COMPILE.c) $(OUTPUT_OPTION) $<
-
-%.ln: $(SRCDIR)/%.c
-	$(LINT.c) $(OUTPUT_OPTION) -c $<
+install: $(ROOTLIBS)
 
 include "../Makefile.lib"
--- a/usr/src/lib/libUnixDomainSocket_jni/Makefile	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libUnixDomainSocket_jni/Makefile	Sat May 28 17:58:14 2011 -0700
@@ -20,31 +20,9 @@
 #
 
 #
-# Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2008, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
-include Makefile.env
+include ../Makefile.env
 include ../Makefile.subdirs
-
-# Jars that must be built prior (added automatically to CLASSPATH)
-DEPENDENCY_JARS = \
-	$(SRC)/java/util/vpanels-util.jar
-
-CLEAN_FILES += $(HEADERS)
-
-include $(SRC)/Makefile.targ
-
-headers: $(HEADERS)
-
-$(HEADERS): $(DEPENDENCY_JARS)
-	@for f in $(DEPENDENCY_JARS); \
-	do \
-		jar tf "$$f"; \
-	done | $(GREP) '/$(@:%.h=%).class' | \
-	$(SED) 's/\.class$$//; s#/#.#g' | \
-	$(XARGS) echo javah -classpath $(CLASS_PATH) -o $@ | \
-	while read line; \
-	do \
-		echo "$$line"; \
-		$$line; \
-	done
+include ../Makefile.targ
--- a/usr/src/lib/libUnixDomainSocket_jni/Makefile.com	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libUnixDomainSocket_jni/Makefile.com	Sat May 28 17:58:14 2011 -0700
@@ -20,38 +20,56 @@
 #
 
 #
-# Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2007, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
-include ../Makefile.env
+LIBRARY = libUnixDomainSocket_jni.a
+VERS = .1
+
+include "../Makefile.com"
 
-TARG = libUnixDomainSocket_jni.so.1
+# Jars that must be built prior (added automatically to CLASSPATH)
+DEPENDENCY_JARS = \
+	$(SRC)/java/util/vpanels-util.jar
+
+NATIVES = \
+	UnixSocket \
+	UnixSocketServer \
+	UnixDomainSocket
+JHEADERS = $(NATIVES:%=%.h)
+
+SRCDIR = ..
 OBJS = $(NATIVES:%=%.o)
-CFLAGS += -D_REENTRANT -I$(ROOT)/usr/include -I/usr/java/include -I/usr/java/include/solaris
-LFLAGS = -L$(ROOT)/usr/lib/$(LLINK) -Wl,-zdefs -ljniutil -lc -lsocket -lbsm
-LPATH = $(ROOT)/usr/lib/$(LDIR)
+SRCS = $(OBJS:%.o=$(SRCDIR)/%.c)
 
-CLEAN_FILES += $(OBJS)
-CLOBBER_FILES += $(TARG)
-
-include $(SRC)/Makefile.targ
-
-all: $(CLASSES) $(TARG)
+CPPFLAGS += -D_REENTRANT -I. -I$(ROOT)/usr/include -I/usr/java/include \
+	-I/usr/java/include/solaris
+LDFLAGS += -L$(ROOTLIBDIR) -ljniutil -lsocket -lbsm
+LIBS = $(DYNLIB)
 
-install: $(TARG)
-	mkdir -p $(LPATH)
-	$(RM) -- $(ROOT)/usr/lib/$(LLINK)
-	ln -fs $(LDIR) $(ROOT)/usr/lib/$(LLINK)
-	/usr/sbin/install -f $(LPATH) -m 755 -s $(TARG)
+CLEAN_FILES += $(JHEADERS) $(OBJS)
+CLOBBER_FILES += $(DYNLIB)
+
+all: $(CLASSES) $(DYNLIB)
 
-$(TARG): $(OBJS)
-	$(CC) $(CCARCH) -G -h $@ -o $@ $(OBJS) $(LFLAGS)
+$(OBJS): $(JHEADERS)
+
+lint: lintcheck 
+
+install: $(ROOTLIBS)
 
-%.o: ../%.c ../%.h
-	$(COMPILE.c) $(OUTPUT_OPTION) $<
+$(JHEADERS): $(DEPENDENCY_JARS)
+	@for f in $(DEPENDENCY_JARS); \
+	do \
+		jar tf "$$f"; \
+	done | $(GREP) '/$(@:%.h=%).class' | \
+	$(SED) 's/\.class$$//; s#/#.#g' | \
+	$(XARGS) echo javah -classpath $(CLASS_PATH) -o $@ | \
+	while read line; \
+	do \
+		echo "$$line"; \
+		$$line; \
+	done
 
-%.ln: ../%.c
-	$(LINT.c) $(OUTPUT_OPTION) -c $<
+include "../Makefile.lib"
 
-../%.h:
-	cd $(@D); $(MAKE) $(@F)
--- a/usr/src/lib/libUnixDomainSocket_jni/Makefile.env	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libUnixDomainSocket_jni/Makefile.env	Sat May 28 17:58:14 2011 -0700
@@ -24,10 +24,3 @@
 #
 
 include "../Makefile.com"
-
-NATIVES = \
-	UnixSocket \
-	UnixSocketServer \
-	UnixDomainSocket
-
-HEADERS = $(NATIVES:%=%.h)
--- a/usr/src/lib/libUnixDomainSocket_jni/UnixDomainSocket.c	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libUnixDomainSocket_jni/UnixDomainSocket.c	Sat May 28 17:58:14 2011 -0700
@@ -19,8 +19,7 @@
  * CDDL HEADER END
  */
 /*
- * Copyright 2010 Sun Microsystems, Inc.  All rights reserved.
- * Use is subject to license terms.
+ * Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
  */
 
 #include <sys/types.h>
@@ -63,6 +62,7 @@
  * Method:    socket_connect
  * Signature: (Ljava/lang/String;)I
  */
+/* ARGSUSED */
 jint
 JP(UnixDomainSocket_socket_1connect)(JNIEnv *env, jclass cls, jstring path)
 {
@@ -99,6 +99,7 @@
  * Method:    socket_bind
  * Signature: (Ljava/lang/String;)I
  */
+/* ARGSUSED */
 jint
 JP(UnixDomainSocket_socket_1bind)(JNIEnv *env, jclass cls, jstring path)
 {
@@ -145,6 +146,7 @@
  * Method:    socket_close
  * Signature: (I)V
  */
+/* ARGSUSED */
 void
 JP(UnixDomainSocket_socket_1close)(JNIEnv *env, jclass cls, jint fd)
 {
@@ -156,6 +158,7 @@
  * Method:    server_close
  * Signature: (I)V
  */
+/* ARGSUSED */
 void
 JP(UnixDomainSocket_server_1close)(JNIEnv *env, jclass cls, jint fd)
 {
@@ -170,6 +173,7 @@
  * Close a socket without relinquishing the fd.  Permits us to safely
  * operate on the socket from one thread and close it from another.
  */
+/* ARGSUSED */
 void
 JP(UnixDomainSocket_socket_1goose)(JNIEnv *env, jclass cls, jint fd)
 {
--- a/usr/src/lib/libUnixDomainSocket_jni/UnixSocket.c	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libUnixDomainSocket_jni/UnixSocket.c	Sat May 28 17:58:14 2011 -0700
@@ -42,6 +42,7 @@
  * Method:    socket_read
  * Signature: (I)I
  */
+/* ARGSUSED */
 jint
 JP(UnixSocket_socket_1read__I)(JNIEnv *env, jobject obj, jint fd)
 {
@@ -63,6 +64,7 @@
  * Method:    socket_read
  * Signature: (I[BII)I
  */
+/* ARGSUSED */
 jint
 JP(UnixSocket_socket_1read__I_3BII)(JNIEnv *env, jobject obj,
     jint fd, jobject b, jint off, jint len)
@@ -102,6 +104,7 @@
  * Method:    socket_skip
  * Signature: (IJ)J
  */
+/* ARGSUSED */
 jlong
 JP(UnixSocket_socket_1skip)(JNIEnv *env, jobject obj, jint fd, jlong n)
 {
@@ -134,6 +137,7 @@
  * Method:    socket_flush
  * Signature: (I)V
  */
+/* ARGSUSED */
 void
 JP(UnixSocket_socket_1flush)(JNIEnv *env, jobject obj, jint fd)
 {
@@ -145,6 +149,7 @@
  * Method:    socket_write
  * Signature: (II)V
  */
+/* ARGSUSED */
 void
 JP(UnixSocket_socket_1write__II)(JNIEnv *env, jobject obj, jint fd, jint b)
 {
@@ -161,6 +166,7 @@
  * Method:    socket_write
  * Signature: (I[BII)V
  */
+/* ARGSUSED */
 void
 JP(UnixSocket_socket_1write__I_3BII)(JNIEnv *env, jobject obj,
     jint fd, jobject b, jint off, jint len)
@@ -188,6 +194,7 @@
  * Method:    socket_peeruser
  * Signature: (I)Ljava/lang/String;
  */
+/* ARGSUSED */
 jstring
 JP(UnixSocket_socket_1peeruser)(JNIEnv *env, jobject obj, jint fd)
 {
@@ -224,6 +231,7 @@
  * Method:    socket_peeraudit
  * Signature: (I)[B
  */
+/* ARGSUSED */
 jbyteArray
 JP(UnixSocket_socket_1peeraudit)(JNIEnv *env, jobject obj, jint fd)
 {
--- a/usr/src/lib/libUnixDomainSocket_jni/UnixSocketServer.c	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libUnixDomainSocket_jni/UnixSocketServer.c	Sat May 28 17:58:14 2011 -0700
@@ -37,6 +37,7 @@
  * Method:    socket_accept
  * Signature: (I)I
  */
+/* ARGSUSED */
 jint
 JP(UnixSocketServer_socket_1accept)(JNIEnv *env, jobject obj, jint fd)
 {
--- a/usr/src/lib/libadr/Makefile	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libadr/Makefile	Sat May 28 17:58:14 2011 -0700
@@ -20,9 +20,9 @@
 #
 
 #
-# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
 include ../Makefile.env
 include ../Makefile.subdirs
-include ../Makefile.lib
+include ../Makefile.targ
--- a/usr/src/lib/libadr/Makefile.com	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libadr/Makefile.com	Sat May 28 17:58:14 2011 -0700
@@ -23,42 +23,36 @@
 # Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
+LIBRARY = libadr.a
+VERS = .1
+
 include "../Makefile.com"
 
-TARG = libadr.so.1
-OBJS = adr.o adr_object.o adr_name.o adr_stream.o adr_typeset.o
+ROOTHDRDIR = $(ROOT)/usr/include/rad
+HDRDIR=../common
+SRCDIR=../common
 
-HDRS=adr.h adr_object.h adr_name.h adr_stream.h adr_typeset.h
-HDRDIR=../common
-ROOTHDRDIR=$(ROOT)/usr/include/rad
+OBJS = adr.o adr_object.o adr_name.o adr_stream.o adr_typeset.o
+HDRS = adr.h adr_object.h adr_name.h adr_stream.h adr_typeset.h
 
-SRCDIR=../common
+$(LINTLIB) :=   SRCS = $(SRCDIR)/$(LINTSRC)
+
+MAPFILES += ../common/mapfile-vers
+
 SRCS=$(OBJS:%.o=$(SRCDIR)/%.c)
 CPPFLAGS = -I$(ROOT)/usr/include
-LFLAGS = -Wl,-zdefs -lc -Wl,-zlazyload -lssl -lcrypto
-LPATH = $(ROOT)/usr/lib/$(LDIR)
+LDFLAGS += -Wl,-zlazyload -lssl -lcrypto
+LIBS = $(SOLIB) $(DYNLIB) $(LINTLIB)
 
 CLEAN_FILES += $(OBJS)
-CLOBBER_FILES += $(TARG)
+CLOBBER_FILES += $(DYNLIB) $(LINTLIB) $(LINTOUT)
 
-all: $(TARG)
-
-$(OBJS): install_h
+all: $(DYNLIB) $(LINTLIB)
 
-install: $(TARG)
-	mkdir -p $(LPATH)
-	$(RM) -- $(ROOT)/usr/lib/$(LLINK)
-	ln -fs $(LDIR) $(ROOT)/usr/lib/$(LLINK)
-	/usr/sbin/install -f $(LPATH) -m 755 -s $(TARG)
-	ln -fs $(TARG) $(LPATH)/$(TARG:%.1=%)
+$(OBJS): $(ROOTHDRS)
 
-$(TARG): $(OBJS)
-	$(CC) $(CCARCH) -G -h $@ -o $@ $(OBJS) $(LFLAGS) $(LDLIBS)
+lint: lintcheck
 
-%.o: $(SRCDIR)/%.c
-	$(COMPILE.c) $(OUTPUT_OPTION) $<
-
-%.ln: $(SRCDIR)/%.c
-	$(LINT.c) $(OUTPUT_OPTION) -c $<
+install: $(ROOTHDRS) $(ROOTLINT) $(ROOTLIBS)
 
 include "../Makefile.lib"
--- a/usr/src/lib/libadr/common/adr.c	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libadr/common/adr.c	Sat May 28 17:58:14 2011 -0700
@@ -246,7 +246,7 @@
 		break;
 	case dt_password:
 		assert(data->d_lifetime != lt_copy);
-		memset((char *)data->d_data.string, 0,
+		(void) memset((char *)data->d_data.string, 0,
 		    strlen(data->d_data.string));
 		free((char *)data->d_data.string);
 		break;
@@ -295,13 +295,13 @@
 		(void) fprintf(file, "%d\n", data->d_data.integer);
 		break;
 	case dt_long:
-		(void) fprintf(file, "%" PRId64 "\n", data->d_data.longint);
+		(void) fprintf(file, "%lld\n", data->d_data.longint);
 		break;
 	case dt_uint:
 		(void) fprintf(file, "%u\n", data->d_data.uinteger);
 		break;
 	case dt_ulong:
-		(void) fprintf(file, "%" PRIu64 "\n", data->d_data.ulongint);
+		(void) fprintf(file, "%llu\n", data->d_data.ulongint);
 		break;
 	case dt_float:
 		(void) fprintf(file, "%g\n", (double)data->d_data.afloat);
@@ -1032,7 +1032,7 @@
 			a2->d_data.array[j] = NULL;
 		} else {
 			/* We have to share */
-			data_ref(d);
+			(void) data_ref(d);
 		}
 	}
 	a1->d_rsize = i;
--- a/usr/src/lib/libadr/common/adr_name.c	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libadr/common/adr_name.c	Sat May 28 17:58:14 2011 -0700
@@ -432,6 +432,7 @@
 	char c, nc;
 	char *start = dst;
 
+	/* LINTED */
 	while (nc = c = *src++) {
 		switch (c) {
 		case '\\':
--- a/usr/src/lib/libadr/common/adr_stream.c	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libadr/common/adr_stream.c	Sat May 28 17:58:14 2011 -0700
@@ -20,7 +20,7 @@
  */
 
 /*
- * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
  */
 
 #include <openssl/ssl.h>
@@ -184,13 +184,14 @@
 	return (pthread_self());
 }
 
+/* ARGSUSED */
 static void
 adr_ssl_locking_function(int mode, int n, const char *file, int line)
 {
 	if (mode & CRYPTO_LOCK)
-		pthread_mutex_lock(&crypto_locks[n]);
+		(void) pthread_mutex_lock(&crypto_locks[n]);
 	else
-		pthread_mutex_unlock(&crypto_locks[n]);
+		(void) pthread_mutex_unlock(&crypto_locks[n]);
 }
 
 void
@@ -200,7 +201,7 @@
 	if (crypto_locks == NULL)
 		abort();
 	for (int i = 0; i < CRYPTO_num_locks(); i++)
-		pthread_mutex_init(&crypto_locks[i], NULL);
+		(void) pthread_mutex_init(&crypto_locks[i], NULL);
 	CRYPTO_set_locking_callback(adr_ssl_locking_function);
 	CRYPTO_set_id_callback(adr_ssl_id_function);
 }
@@ -266,15 +267,15 @@
 		 * thread to read/write the data we were polling for.
 		 * Much simpler than implementing a precise wakeup.
 		 */
-		pthread_mutex_unlock(&sslstr->lock);
+		(void) pthread_mutex_unlock(&sslstr->lock);
 		if (poll(&pfd, 1, 5 * MILLISEC) >= 0)
 			return (B_TRUE);
-		pthread_mutex_lock(&sslstr->lock);
+		(void) pthread_mutex_lock(&sslstr->lock);
 	}
 
 out:
 	adr_sslstream_close_locked(sslstr);
-	pthread_mutex_unlock(&sslstr->lock);
+	(void) pthread_mutex_unlock(&sslstr->lock);
 	return (B_FALSE);
 }
 
@@ -284,19 +285,19 @@
 	int res;
 	adr_sslstream_t *sslstr = data;
 	do {
-		pthread_mutex_lock(&sslstr->lock);
+		(void) pthread_mutex_lock(&sslstr->lock);
 		/*
 		 * We're done.
 		 */
 		if (sslstr->closed) {
-			pthread_mutex_unlock(&sslstr->lock);
+			(void) pthread_mutex_unlock(&sslstr->lock);
 			return (0);
 		}
 
 		ERR_clear_error();
 		res = SSL_read(sslstr->ssl, buf, len);
 		if (res > 0) {
-			pthread_mutex_unlock(&sslstr->lock);
+			(void) pthread_mutex_unlock(&sslstr->lock);
 			return (res);
 		}
 
@@ -312,19 +313,19 @@
 	int res;
 	adr_sslstream_t *sslstr = data;
 	do {
-		pthread_mutex_lock(&sslstr->lock);
+		(void) pthread_mutex_lock(&sslstr->lock);
 		/*
 		 * We're done.
 		 */
 		if (sslstr->closed) {
-			pthread_mutex_unlock(&sslstr->lock);
+			(void) pthread_mutex_unlock(&sslstr->lock);
 			return (0);
 		}
 
 		ERR_clear_error();
 		res = SSL_write(sslstr->ssl, buf, len);
 		if (res > 0) {
-			pthread_mutex_unlock(&sslstr->lock);
+			(void) pthread_mutex_unlock(&sslstr->lock);
 			return (res);
 		}
 
@@ -338,9 +339,9 @@
 adr_sslstream_close(void *data)
 {
 	adr_sslstream_t *sslstr = data;
-	pthread_mutex_lock(&sslstr->lock);
+	(void) pthread_mutex_lock(&sslstr->lock);
 	adr_sslstream_close_locked(sslstr);
-	pthread_mutex_unlock(&sslstr->lock);
+	(void) pthread_mutex_unlock(&sslstr->lock);
 }
 
 static void
@@ -366,7 +367,7 @@
 	sslstr->ssl = ssl;
 	sslstr->fd = fd;
 	sslstr->closed = B_FALSE;
-	pthread_mutex_init(&sslstr->lock, NULL);
+	(void) pthread_mutex_init(&sslstr->lock, NULL);
 
 	int flags = fcntl(fd, F_GETFL, 0);
 	(void) fcntl(fd, F_SETFL, flags | O_NONBLOCK);
--- a/usr/src/lib/libadr/common/adr_typeset.c	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libadr/common/adr_typeset.c	Sat May 28 17:58:14 2011 -0700
@@ -116,13 +116,10 @@
 void
 typeset_insert_all(typeset_t *typeset, type_t *type)
 {
-	int tnum;
-
 	if (type == NULL)
 		return;
 
-	if (!DT_DERIVED(type->t_type) ||
-	    (tnum = typeset_find(typeset, type)) >= 0)
+	if (!DT_DERIVED(type->t_type) || typeset_find(typeset, type) >= 0)
 		return;
 
 	if (type->t_type == dt_array) {
@@ -140,7 +137,7 @@
 		}
 	}
 
-	typeset_insert(typeset, type);
+	(void) typeset_insert(typeset, type);
 }
 
 /*
@@ -159,7 +156,6 @@
 	switch (type->t_type) {
 	case dt_array:
 		return (1 + typeset_count(type->t_aux.t_array));
-		break;
 	case dt_struct: {
 		int total = 1;
 		for (int i = 0; i < type->t_size; i++)
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/usr/src/lib/libadr/common/llib-ladr	Sat May 28 17:58:14 2011 -0700
@@ -0,0 +1,32 @@
+/*
+ * 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
+ */
+/* LINTLIBRARY */
+/* PROTOLIB1 */
+
+/*
+ * Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
+ */
+
+#include <rad/adr.h>
+#include <rad/adr_name.h>
+#include <rad/adr_object.h>
+#include <rad/adr_stream.h>
+#include <rad/adr_typeset.h>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/usr/src/lib/libadr/common/mapfile-vers	Sat May 28 17:58:14 2011 -0700
@@ -0,0 +1,175 @@
+#
+# 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 (c) 2011, Oracle and/or its affiliates. All rights reserved.
+#
+
+$mapfile_version 2
+
+SYMBOL_VERSION SUNWprivate_1.1 {
+    global:
+    	# adr.h
+	t_void { ASSERT { TYPE=data; } };
+	t_string { ASSERT { TYPE=data; } };
+	t_integer { ASSERT { TYPE=data; } };
+	t_uinteger { ASSERT { TYPE=data; } };
+	t_long { ASSERT { TYPE=data; } };
+	t_ulong { ASSERT { TYPE=data; } };
+	t_time { ASSERT { TYPE=data; } };
+	t_object { ASSERT { TYPE=data; } };
+	t_boolean { ASSERT { TYPE=data; } };
+	t_opaque { ASSERT { TYPE=data; } };
+	t_password { ASSERT { TYPE=data; } };
+	t_float { ASSERT { TYPE=data; } };
+	t_double { ASSERT { TYPE=data; } };
+
+	t_array_string { ASSERT { TYPE=data; } };
+	t_array_integer { ASSERT { TYPE=data; } };
+	t_array_uinteger { ASSERT { TYPE=data; } };
+	t_array_long { ASSERT { TYPE=data; } };
+	t_array_ulong { ASSERT { TYPE=data; } };
+	t_array_time { ASSERT { TYPE=data; } };
+	t_array_object { ASSERT { TYPE=data; } };
+	t_array_boolean { ASSERT { TYPE=data; } };
+	t_array_opaque { ASSERT { TYPE=data; } };
+	t_array_password { ASSERT { TYPE=data; } };
+	t_array_float { ASSERT { TYPE=data; } };
+	t_array_double { ASSERT { TYPE=data; } };
+
+	d_true { ASSERT { TYPE=data; } };
+	d_false { ASSERT { TYPE=data; } };
+
+	array_add;
+	array_addall;
+	array_nsearch;
+	array_remove;
+	array_removeall;
+	array_search;
+	array_set;
+	array_type;
+	array_vset;
+	arraytype;
+	basetype;
+	data_basetype;
+	data_free;
+	data_get_internal;
+	data_new_array;
+	data_new_boolean;
+	data_new_double;
+	data_new_enum;
+	data_new_enum_byname;
+	data_new_enum_index;
+	data_new_float;
+	data_new_fstring;
+	data_new_integer;
+	data_new_long;
+	data_new_nstring;
+	data_new_object;
+	data_new_opaque;
+	data_new_password;
+	data_new_string;
+	data_new_struct;
+	data_new_time;
+	data_new_uinteger;
+	data_new_ulong;
+	data_new_union;
+	data_new_union_indexed;
+	data_print;
+	data_purify;
+	data_ref;
+	data_ref_n;
+	data_type;
+	data_verify;
+	enum_tostring;
+	enum_tovalue;
+	opaque_cmp;
+	rad_split;
+	rad_strarray;
+	string_cmp;
+	strtype;
+	struct_get;
+	struct_merge;
+	struct_nset;
+	struct_set;
+	struct_set_internal;	# externed
+	type_free;
+	type_print;
+	type_struct_get;
+	type_struct_nget;
+	union_arm_type;
+	union_get;
+	union_get_arm;
+
+    	# adr_stream.h
+	adr_ssl_init;
+	adr_stream_close;
+	adr_stream_create;
+	adr_stream_create_fd;
+	adr_stream_create_fds;
+	adr_stream_create_ssl;
+	adr_stream_free;
+	adr_stream_read;
+	adr_stream_write;
+
+    	# adr_typeset.h
+	typeset_compact;
+	typeset_count;
+	typeset_create;
+	typeset_find;
+	typeset_free;
+	typeset_id;
+	typeset_insert;
+	typeset_insert_all;
+	typeset_object;
+
+    	# adr_name.h
+	adr_name_cmp;
+	adr_name_compose;
+	adr_name_create;
+	adr_name_domain;
+	adr_name_fromstr;
+	adr_name_fromstr_x;
+	adr_name_hold;
+	adr_name_key;
+	adr_name_key_n;
+	adr_name_match;
+	adr_name_nkeys;
+	adr_name_rele;
+	adr_name_tostr;
+	adr_name_value_n;
+	adr_name_vcompose;
+	adr_name_vcreate;
+
+    	# adr_object.h
+	adr_free;
+	adr_get_attr;
+	adr_get_event;
+	adr_get_method;
+	adr_lookup_attr;
+	adr_lookup_attr_index;
+	adr_lookup_event;
+	adr_lookup_event_index;
+	adr_lookup_method;
+	adr_lookup_method_index;
+    local:
+	*;
+};
+
--- a/usr/src/lib/libadr_mdb/Makefile	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libadr_mdb/Makefile	Sat May 28 17:58:14 2011 -0700
@@ -20,9 +20,9 @@
 #
 
 #
-# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
 include ../Makefile.env
 include ../Makefile.subdirs
-include ../Makefile.lib
+include ../Makefile.targ
--- a/usr/src/lib/libadr_mdb/Makefile.com	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libadr_mdb/Makefile.com	Sat May 28 17:58:14 2011 -0700
@@ -20,32 +20,32 @@
 #
 
 #
-# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
+LIBRARY = libadr.so
+VERS =
+
 include "../Makefile.com"
 
-TARG = libadr.so
+ROOTLIBBASE=$(PROTO_LIB)/mdb/proc
+SOLIB=__none__
+
 OBJS = adr.o adr_object.o
 
 SRCDIR=../common
 SRCS=$(OBJS:%.o=$(SRCDIR)/%.c)
 CPPFLAGS = -I$(ROOT)/usr/include
-LPATH = $(ROOT)/usr/lib/mdb/proc/$(LDIR)
+LDFLAGS = $(MAPOPTS)
+LIBS = $(DYNLIB)
 
 CLEAN_FILES += $(OBJS)
-CLOBBER_FILES += $(TARG)
+CLOBBER_FILES += $(DYNLIB)
 
 all: $(TARG)
 
-install: $(TARG)
-	mkdir -p $(LPATH)
-	/usr/sbin/install -f $(LPATH) -m 755 -s $(TARG)
+lint: lintcheck
 
-$(TARG): $(OBJS)
-	$(CC) $(CCARCH) -G -h $@ -o $@ $(OBJS) $(LFLAGS) $(LDLIBS)
-
-%.o: $(SRCDIR)/%.c
-	$(COMPILE.c) $(OUTPUT_OPTION) $<
+install: $(ROOTLIBS)
 
 include "../Makefile.lib"
--- a/usr/src/lib/libadr_mdb/common/adr_object.c	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libadr_mdb/common/adr_object.c	Sat May 28 17:58:14 2011 -0700
@@ -20,7 +20,7 @@
  */
 
 /*
- * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
  */
 
 #include <stdlib.h>
@@ -66,6 +66,7 @@
 	case s_committed:
 		return ("com");
 	}
+	return ("INVAL");
 }
 
 static boolean_t
@@ -84,6 +85,7 @@
 	return (B_TRUE);
 }
 
+/* ARGSUSED */
 int
 cmd_attribute(uintptr_t addr, uint_t flags, int argc, const mdb_arg_t *argv)
 {
@@ -111,6 +113,7 @@
 	return (DCMD_OK);
 }
 
+/* ARGSUSED */
 int
 cmd_method(uintptr_t addr, uint_t flags, int argc, const mdb_arg_t *argv)
 {
@@ -135,6 +138,7 @@
 	return (DCMD_OK);
 }
 
+/* ARGSUSED */
 int
 cmd_object(uintptr_t addr, uint_t flags, int argc, const mdb_arg_t *argv)
 {
--- a/usr/src/lib/libjniutil/Makefile	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libjniutil/Makefile	Sat May 28 17:58:14 2011 -0700
@@ -20,15 +20,9 @@
 #
 
 #
-# Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2007, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
-include Makefile.env
+include ../Makefile.env
 include ../Makefile.subdirs
-
-HEADERS=libjniutil.h
-include $(SRC)/Makefile.targ
-
-install: $(HEADERS)
-	mkdir -p $(ROOT)/usr/include
-	install -f $(ROOT)/usr/include -m 644 -s $(HEADERS)
+include ../Makefile.targ
--- a/usr/src/lib/libjniutil/Makefile.com	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libjniutil/Makefile.com	Sat May 28 17:58:14 2011 -0700
@@ -20,39 +20,34 @@
 #
 
 #
-# Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2007, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
-include ../Makefile.env
+LIBRARY = libjniutil.a
+VERS = .1
+
+include "../Makefile.com"
 
-TARG = libjniutil.so.1
+SRCDIR = ..
+HDRDIR = ..
+
+HDRS = libjniutil.h
 OBJS = libjniutil.o
-CFLAGS += -I/usr/java/include -I/usr/java/include/solaris
-LFLAGS = -Wl,-zdefs -lc
-LPATH = $(ROOT)/usr/lib/$(LDIR)
+SRCS=$(OBJS:%.o=$(SRCDIR)/%.c)
+
+$(LINTLIB) := SRCS = $(SRCDIR)/$(LINTSRC)
+
+CPPFLAGS += -I$(ROOT)/usr/include -I/usr/java/include \
+	-I/usr/java/include/solaris
+LIBS = $(SOLIB) $(DYNLIB) $(LINTLIB)
 
 CLEAN_FILES += $(OBJS)
-CLOBBER_FILES += $(TARG)
-
-include $(SRC)/Makefile.targ
+CLOBBER_FILES += $(DYNLIB) $(LINTLIB) $(LINTOUT)
 
 all: $(TARG)
 
-install: $(TARG)
-	mkdir -p $(LPATH)
-	$(RM) -- $(ROOT)/usr/lib/$(LLINK)
-	ln -fs $(LDIR) $(ROOT)/usr/lib/$(LLINK)
-	/usr/sbin/install -f $(LPATH) -m 755 -s $(TARG)
-	ln -fs $(TARG) $(LPATH)/$(TARG:%.1=%)
+lint: lintcheck
 
-$(TARG): $(OBJS)
-	$(CC) $(CCARCH) -G -h $@ -o $@ $(OBJS) $(LFLAGS)
-
-%.o: ../%.c ../%.h
-	$(COMPILE.c) $(OUTPUT_OPTION) $<
+install: $(ROOTHDRS) $(ROOTLIBS) $(ROOTLINT)
 
-%.ln: ../%.c
-	$(LINT.c) $(OUTPUT_OPTION) -c $<
-
-../%.h:
-	cd $(@D); $(MAKE) $(@F)
+include "../Makefile.lib"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/usr/src/lib/libjniutil/llib-ljniutil	Sat May 28 17:58:14 2011 -0700
@@ -0,0 +1,28 @@
+/*
+ * 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
+ */
+/* LINTLIBRARY */
+/* PROTOLIB1 */
+
+/*
+ * Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
+ */
+
+#include <libjniutil.h>
--- a/usr/src/lib/libradproto/Makefile	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libradproto/Makefile	Sat May 28 17:58:14 2011 -0700
@@ -20,17 +20,10 @@
 #
 
 #
-# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
 include ../Makefile.env
 include ../Makefile.subdirs
-
-HDRS=radclient.h radproto.h radproto_util.h radproto_adr.h
-HDRDIR=common
-ROOTHDRDIR=$(ROOT)/usr/include/rad
+include ../Makefile.targ
 
-include ../Makefile.lib
-
-install: install_h
-	rpcgen -h -o $(ROOTHDRDIR)/protocol.h common/protocol.x
--- a/usr/src/lib/libradproto/Makefile.com	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libradproto/Makefile.com	Sat May 28 17:58:14 2011 -0700
@@ -20,36 +20,44 @@
 #
 
 #
-# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
+LIBRARY = libradproto.a
+VERS = .1
+
 include "../Makefile.com"
 
-TARG = libradproto.so.1
-OBJS = radclient.o radproto_adr.o radproto_util.o protocol_xdr.o
-
+ROOTHDRDIR=$(ROOT)/usr/include/rad
+HDRDIR=../common
 SRCDIR=../common
-SRCS=$(OBJS:%.o=$(SRCDIR)/%.c)
-CFLAGS += -I. -I$(ROOT)/usr/include
-LPATH = $(ROOT)/usr/lib/$(LDIR)
-LFLAGS = -Wl,-zdefs -lc -L$(LPATH) -ladr -lnsl
 
-CLEAN_FILES += $(OBJS)
-CLOBBER_FILES += $(TARG)
+HDRS=radclient.h radproto.h radproto_util.h radproto_adr.h protocol.h
+SOBJS = radclient.o radproto_adr.o radproto_util.o
+GOBJS = protocol_xdr.o
+OBJS = $(SOBJS) $(GOBJS)
+
+$(LINTLIB) := SRCS = $(SRCDIR)/$(LINTSRC)
+
+MAPFILES += ../common/mapfile-vers
 
-include $(SRC)/Makefile.targ
-
-all: $(TARG)
+SSRCS=$(SOBJS:%.o=$(SRCDIR)/%.c)
+GSRCS=$(GOBJS:%.o=%.c) protocol.h protocol.x
+SRCS=$(SSRCS)
+CPPFLAGS = -I. -I$(ROOT)/usr/include
+LDFLAGS += -L$(ROOTLIBDIR) -ladr -lnsl
+LIBS = $(SOLIB) $(DYNLIB) $(LINTLIB)
 
-install: $(TARG)
-	mkdir -p $(LPATH)
-	$(RM) -- $(ROOT)/usr/lib/$(LLINK)
-	ln -fs $(LDIR) $(ROOT)/usr/lib/$(LLINK)
-	/usr/sbin/install -f $(LPATH) -m 755 -s $(TARG)
-	ln -fs $(TARG) $(LPATH)/$(TARG:%.1=%)
+CLEAN_FILES += $(OBJS) $(GSRCS)
+CLOBBER_FILES += $(LIBS) $(LINTOUT)
+
+all: $(DYNLIB) $(LINTLIB)
 
-$(TARG): $(OBJS)
-	$(CC) $(CCARCH) -G -h $@ -o $@ $(OBJS) $(LFLAGS) $(LDLIBS)
+$(SOBJS): $(ROOTHDRS)
+
+lint: lintcheck
+
+install: $(ROOTHDRS) $(ROOTLINT) $(ROOTLIBS)
 
 radclient.o: protocol.h
 
@@ -57,8 +65,7 @@
 	cp $(SRCDIR)/protocol.x .
 	rpcgen protocol.x
 
-%.o: $(SRCDIR)/%.c
-	$(COMPILE.c) $(OUTPUT_OPTION) $<
+$(ROOTHDRDIR)/%.h: $(SRCDIR)/%.x
+	rpcgen -h -o $@ $<
 
-%.ln: $(SRCDIR)/%.c
-	$(LINT.c) $(OUTPUT_OPTION) -c $<
+include "../Makefile.lib"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/usr/src/lib/libradproto/common/llib-lradproto	Sat May 28 17:58:14 2011 -0700
@@ -0,0 +1,31 @@
+/*
+ * 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
+ */
+/* LINTLIBRARY */
+/* PROTOLIB1 */
+
+/*
+ * Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
+ */
+
+#include <rad/radclient.h>
+#include <rad/protocol.h>
+#include <rad/radproto_adr.h>
+#include <rad/radproto_util.h>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/usr/src/lib/libradproto/common/mapfile-vers	Sat May 28 17:58:14 2011 -0700
@@ -0,0 +1,82 @@
+#
+# 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 (c) 2011, Oracle and/or its affiliates. All rights reserved.
+#
+
+$mapfile_version 2
+
+SYMBOL_VERSION SUNWprivate_1.1 {
+    global:
+	# radclient.h
+	rc_arraytype;
+	rc_connect;
+	rc_connect_fd;
+	rc_disconnect;
+	rc_get;
+	rc_invoke;
+	rc_list;
+	rc_lookup;
+	rc_lookup_typed;
+	rc_release;
+	rc_set;
+	rc_set_threaded;
+	rc_thread;
+	rc_type;
+
+	# radproto_adr.h
+	xdr_data_t;
+	xdr_object_t;
+	xdr_optdata_t;
+	xdr_r_data_t;
+	xdr_r_object_t;
+	xdr_r_optdata_t;
+	xdr_r_typeref_t;
+	xdr_r_typeset_t;
+	xdr_typeref_t;
+	xdr_typeset_t;
+	xdr_unembed_optdata;
+
+	# radproto_util.h
+	xdr_embed;
+	xdr_unembed;
+	xdr_recpair;
+
+	# protocol.h
+	xdr_client_hello;
+	xdr_message;
+	xdr_op_define;
+	xdr_op_getattr;
+	xdr_op_invoke;
+	xdr_op_list;
+	xdr_op_lookup;
+	xdr_op_setattr;
+	xdr_op_subscribe;
+	xdr_op_unsubscribe;
+	xdr_operation;
+	xdr_request;
+	xdr_resp_list;
+	xdr_server_hello;
+    local:
+	*;
+};
+
+
--- a/usr/src/lib/libradproto/common/radclient.c	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libradproto/common/radclient.c	Sat May 28 17:58:14 2011 -0700
@@ -132,12 +132,14 @@
 	return (adr_stream_write(client->rrc_stream, buf, len));
 }
 
+/* ARGSUSED */
 type_t *
 rc_type(rc_object_t *o, const char *name)
 {
 	return (NULL);
 }
 
+/* ARGSUSED */
 type_t *
 rc_arraytype(rc_object_t *o, type_t *type)
 {
@@ -343,6 +345,10 @@
 	return (mw);
 }
 
+#if 0
+/*
+ * Unused at the moment.
+ */
 static message_wrapper_t *
 find_event(rc_conn_t *client, const char *name)
 {
@@ -373,6 +379,7 @@
 
 	return (result);
 }
+#endif
 
 void
 rc_set_threaded(rc_conn_t *client, boolean_t threaded)
@@ -507,7 +514,6 @@
 void
 rc_response_error(message_wrapper_t *mw, data_t **error, type_t *etype)
 {
-	XDR mxdr;
 	fault *fault = &mw->message.message_u.rdata.response_data_u.faulty;
 	(void) xdr_unembed_optdata(error, etype,
 	    fault->payload.payload_len, fault->payload.payload_val);
@@ -678,7 +684,6 @@
 {
 	op_list listreq = { "" };
 	resp_list listresp = { 0 };
-	int serial;
 
 	message_wrapper_t *mw = NULL;
 	rc_err_t res = radclient_write_sync(
--- a/usr/src/lib/libradproto/common/radproto_adr.c	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/lib/libradproto/common/radproto_adr.c	Sat May 28 17:58:14 2011 -0700
@@ -159,7 +159,6 @@
 	}
 	case dt_struct: {
 		char *name = NULL;
-		int size;
 
 		if (!xdr_string(xdrs, &name, -1))
 			goto error;
@@ -183,7 +182,6 @@
 	}
 	case dt_union: {
 		char *name = NULL;
-		int size;
 		bool_t dflt, dfltopt;
 		type_t *dflttype = NULL, *utype;
 
@@ -221,7 +219,6 @@
 	}
 	case dt_enum: {
 		char *name = NULL, *fbname = NULL;
-		int size;
 		bool_t fallback;
 
 		if (!xdr_string(xdrs, &name, -1))
@@ -255,7 +252,7 @@
 	}
 	}
 
-	typeset_insert(typeset, result);
+	(void) typeset_insert(typeset, result);
 	return (TRUE);
 
 error:
--- a/usr/src/pkg/manifests/system-management-rad.p5m	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/pkg/manifests/system-management-rad.p5m	Sat May 28 17:58:14 2011 -0700
@@ -47,13 +47,19 @@
 file path=usr/include/rad/adr_stream.h facet.devel=true
 file path=usr/include/rad/radclient.h facet.devel=true
 file path=usr/include/rad/rad_modapi.h facet.devel=true
+file path=usr/lib/llib-ladr facet.devel=true
+file path=usr/lib/llib-ladr.ln facet.devel=true
 file path=usr/lib/libadr.so.1
 link path=usr/lib/libadr.so target=libadr.so.1 facet.devel=true
+file path=usr/lib/llib-lradproto facet.devel=true
+file path=usr/lib/llib-lradproto.ln facet.devel=true
 file path=usr/lib/libradproto.so.1
 link path=usr/lib/libradproto.so target=libradproto.so.1 facet.devel=true
 dir path=usr/lib/$(ARCH64)
+file path=usr/lib/$(ARCH64)/llib-ladr.ln facet.devel=true
 file path=usr/lib/$(ARCH64)/libadr.so.1
 link path=usr/lib/$(ARCH64)/libadr.so target=libadr.so.1 facet.devel=true
+file path=usr/lib/$(ARCH64)/llib-lradproto.ln facet.devel=true
 file path=usr/lib/$(ARCH64)/libradproto.so.1
 link path=usr/lib/$(ARCH64)/libradproto.so target=libradproto.so.1 facet.devel=true
 dir path=usr/lib/mdb group=sys
--- a/usr/src/test/c/Makefile.com	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/test/c/Makefile.com	Sat May 28 17:58:14 2011 -0700
@@ -38,3 +38,5 @@
 
 %: %.o
 	cc -o $@ $< ../common/test.a $(LDFLAGS) $(LDLIBS)
+
+lint:
--- a/usr/src/test/c/common/Makefile	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/test/c/common/Makefile	Sat May 28 17:58:14 2011 -0700
@@ -32,3 +32,5 @@
 
 clean clobber:
 	$(RM) $(OBJS) test.a
+
+lint:
--- a/usr/src/test/java/Makefile	Thu May 26 15:30:06 2011 -0700
+++ b/usr/src/test/java/Makefile	Sat May 28 17:58:14 2011 -0700
@@ -55,3 +55,5 @@
 
 clean clobber:
 	$(RM) -rf $(BUILD)
+
+lint: