diff options
author | Rod Evans <Rod.Evans@Sun.COM> | 2009-05-07 16:01:18 -0700 |
---|---|---|
committer | Rod Evans <Rod.Evans@Sun.COM> | 2009-05-07 16:01:18 -0700 |
commit | 2a8d6eba033e4713ab12b61178f0513f1f075482 (patch) | |
tree | 0fd82f40b89008aa56426a55126371550f5b2309 | |
parent | c03aa62609f1d65e84421396e8ee70875fc77b30 (diff) | |
download | illumos-gate-2a8d6eba033e4713ab12b61178f0513f1f075482.tar.gz |
6806791 filter builds could be optimized
6823371 calloc() uses suboptimal memset() causing 15% regression in SpecCPU2006 gcc code
--HG--
rename : usr/src/lib/libkrb5/common/mapfile => usr/src/lib/libkrb5/common/mapfile-vers
103 files changed, 790 insertions, 1169 deletions
diff --git a/usr/src/Makefile.master b/usr/src/Makefile.master index 7534f1fdef..5b9433a995 100644 --- a/usr/src/Makefile.master +++ b/usr/src/Makefile.master @@ -773,6 +773,7 @@ ZNODELETE= -znodelete ZNODLOPEN= -znodlopen ZNODUMP= -znodump ZNOLAZYLOAD= -znolazyload +ZNOLDYNSYM= -znoldynsym ZNORELOC= -znoreloc ZNOVERSION= -znoversion ZRECORD= -zrecord diff --git a/usr/src/Makefile.master.64 b/usr/src/Makefile.master.64 index 10f22738cb..5256716715 100644 --- a/usr/src/Makefile.master.64 +++ b/usr/src/Makefile.master.64 @@ -19,7 +19,7 @@ # 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. # @@ -74,6 +74,11 @@ REAL_CCC= $(CW_CCC_CMD:sh) BUILD.SO= $(CC) $(CFLAGS) -o $@ $(GSHARED) $(DYNFLAGS) \ $(PICS) -L $(ROOTLIBDIR64) $(LDLIBS) +# +# ld(1) requires the -64 option to create a 64-bit filter solely from a mapfile +# +MAPFILECLASS= -64 + CCNEEDED = -lCrun $(__GNUC64)CCNEEDED = -L$(SFWLIBDIR) -R$(SFWLIBDIR) -lstdc++ \ -lgcc_s_$(MACH64) diff --git a/usr/src/cmd/sgs/Makefile.var b/usr/src/cmd/sgs/Makefile.var index e3239f09e1..e1f33eff45 100644 --- a/usr/src/cmd/sgs/Makefile.var +++ b/usr/src/cmd/sgs/Makefile.var @@ -132,12 +132,6 @@ VAR_LDDSTUB_INTERP= -I'$$ORIGIN/ld.so.1' VAR_LIBCONV_CPPFLAGS= # -# libdl -# -VAR_LIBDL_ROOT4LINK_LIBLINKPATH= ../../lib/ -VAR_LIBDL_ETCDYNLIB= - -# # libelf # VAR_LIBELF_LDLIBS= diff --git a/usr/src/cmd/sgs/libdl/Makefile.com b/usr/src/cmd/sgs/libdl/Makefile.com index 09e27433e1..90fe1ceb0e 100644 --- a/usr/src/cmd/sgs/libdl/Makefile.com +++ b/usr/src/cmd/sgs/libdl/Makefile.com @@ -19,57 +19,14 @@ # CDDL HEADER END # # -# Copyright 2007 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" -# - -LIBRARY= libdl.a -VERS= .1 - -include $(SRC)/lib/Makefile.lib -include $(SRC)/cmd/sgs/Makefile.com - -SRCDIR = ../common - -MAPFILES += mapfile-vers $(MAPFILE.FLT) - -# Redefine shared object build rule to use $(LD) directly (this avoids .init -# and .fini sections being added). Also, since there are no OBJECTS, turn -# off CTF. - -BUILD.SO= $(LD) -o $@ -G $(DYNFLAGS) -CTFMERGE_LIB= : - -DYNFLAGS += $(ZNODUMP) $(VERSREF) $(CONVLIBDIR) -lconv -LINTFLAGS += -u -LINTFLAGS64 += -u -SRCS= ../common/llib-ldl +LIBRARY = libdl.a +VERS = .1 -CLEANFILES += -CLOBBERFILES += $(DYNLIB) $(LINTLIB) $(LINTOUTS) $(LIBLINKS) - - -ROOTFS_DYNLIB64= $(DYNLIB:%=$(ROOTFS_LIBDIR64)/%) -ROOTFS_LINTLIB64= $(LINTLIB:%=$(ROOTFS_LIBDIR64)/%) - -# -# In the libc/libthread unified environment: -# This library needs to be placed in /lib to allow -# dlopen() functionality while in single-user mode. -ROOTFS_DYNLIB= $(DYNLIB:%=$(ROOTFS_LIBDIR)/%) -ROOTFS_LINTLIB= $(LINTLIB:%=$(ROOTFS_LIBDIR)/%) - -$(ROOTFS_DYNLIB) := FILEMODE= 755 -$(ROOTFS_DYNLIB64) := FILEMODE= 755 - -# -# In the libc/libthread un-unified environment: -# A version of this library needs to be placed in /etc/lib to allow -# dlopen() functionality while in single-user mode. -ETCLIBDIR= $(ROOT)/etc/lib -ETCDYNLIB= $(DYNLIB:%=$(ETCLIBDIR)/%) +include $(SRC)/lib/Makefile.rootfs -$(ETCDYNLIB) := FILEMODE= 755 +LIBS += $(LINTLIB) +MAPFILES += mapfile-vers diff --git a/usr/src/cmd/sgs/libdl/amd64/Makefile b/usr/src/cmd/sgs/libdl/amd64/Makefile index e2bc6ec326..90e6d5bf3a 100644 --- a/usr/src/cmd/sgs/libdl/amd64/Makefile +++ b/usr/src/cmd/sgs/libdl/amd64/Makefile @@ -19,25 +19,16 @@ # CDDL HEADER END # # -# 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" -# +include $(SRC)/lib/Makefile.filter.com include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -CONVLIBDIR= $(CONVLIBDIR64) -DYNFLAGS += -F /usr/lib/$(MACH64)/ld.so.1 -64 -LINTFLAGS64 += $(VAR_LINTFLAGS64) - -.KEEP_STATE: - -include ../Makefile.targ -include ../../Makefile.sub.64 - -all: $(DYNLIB) $(LINTLIB) +DYNFLAGS += -F /usr/lib/$(MACH64)/ld.so.1 -install: all $(ROOTFS_DYNLIB64) $(ROOTFS_LINKS64) $(ROOTFS_LINTLIB64) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) $(PICS) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/cmd/sgs/libdl/i386/Makefile b/usr/src/cmd/sgs/libdl/i386/Makefile index 9c83ff9ca9..3faec045c9 100644 --- a/usr/src/cmd/sgs/libdl/i386/Makefile +++ b/usr/src/cmd/sgs/libdl/i386/Makefile @@ -19,26 +19,15 @@ # CDDL HEADER END # # -# 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" -# +include $(SRC)/lib/Makefile.filter.com include ../Makefile.com DYNFLAGS += -F /usr/lib/ld.so.1 -.KEEP_STATE: - -include ../Makefile.targ - - -all: $(DYNLIB) $(LINTLIB) - -install: all $(ROOTFS_DYNLIB) $(VAR_LIBDL_ETCDYNLIB) \ - $(ROOTFS_LINKS) \ - $(ROOTFS_LINTLIB) $(ROOTFS_LIBDIR)/$(LINTLIBSRC) +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -$(VAR_POUND_1)$(ROOTFS_LIBDIR)/$(LINTLIBSRC): ../common/$(LINTLIBSRC) -$(VAR_POUND_1) $(INS.file) ../common/$(LINTLIBSRC) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/cmd/sgs/libdl/sparc/Makefile b/usr/src/cmd/sgs/libdl/sparc/Makefile index 9dedb74d9d..6bc95b1ea1 100644 --- a/usr/src/cmd/sgs/libdl/sparc/Makefile +++ b/usr/src/cmd/sgs/libdl/sparc/Makefile @@ -19,37 +19,28 @@ # CDDL HEADER END # # -# 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" -# - -4VERS= .0 +include $(SRC)/lib/Makefile.filter.com include ../Makefile.com DYNFLAGS += -F /usr/lib/ld.so.1 # A symbolic link from /usr/4lib/libdl.so.1.0 is required for BCP. -4DYNLIB= libdl.so.1$(4VERS) -ROOT4LIBDIR= $(ROOT)/usr/4lib -ROOT4LINKS= $(ROOT4LIBDIR)/$(4DYNLIB) -$(ROOT4LINKS):= LIBLINKPATH = $(VAR_LIBDL_ROOT4LINK_LIBLINKPATH) - -.KEEP_STATE: +4VERS = .0 -include ../Makefile.targ +4DYNLIB = libdl.so.1$(4VERS) +ROOT4LIBDIR = $(ROOT)/usr/4lib +ROOT4LINKS = $(ROOT4LIBDIR)/$(4DYNLIB) +$(ROOT4LINKS):= LIBLINKPATH = ../../lib/ -all: $(DYNLIB) $(LINTLIB) - -install: all $(ROOTFS_DYNLIB) $(VAR_LIBDL_ETCDYNLIB) \ - $(ROOTFS_LINKS) $(ROOT4LINKS) \ - $(ROOTFS_LINTLIB) $(ROOTFS_LIBDIR)/$(LINTLIBSRC) - -$(VAR_POUND_1)$(ROOTFS_LIBDIR)/$(LINTLIBSRC): ../common/$(LINTLIBSRC) -$(VAR_POUND_1) $(INS.file) ../common/$(LINTLIBSRC) +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) \ + $(ROOT4LINKS) $(ROOT4LINKS): $(ROOTFS_DYNLIB) - $(INS.liblink) + $(INS.liblink) + +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/cmd/sgs/libdl/sparcv9/Makefile b/usr/src/cmd/sgs/libdl/sparcv9/Makefile index e2bc6ec326..90e6d5bf3a 100644 --- a/usr/src/cmd/sgs/libdl/sparcv9/Makefile +++ b/usr/src/cmd/sgs/libdl/sparcv9/Makefile @@ -19,25 +19,16 @@ # CDDL HEADER END # # -# 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" -# +include $(SRC)/lib/Makefile.filter.com include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -CONVLIBDIR= $(CONVLIBDIR64) -DYNFLAGS += -F /usr/lib/$(MACH64)/ld.so.1 -64 -LINTFLAGS64 += $(VAR_LINTFLAGS64) - -.KEEP_STATE: - -include ../Makefile.targ -include ../../Makefile.sub.64 - -all: $(DYNLIB) $(LINTLIB) +DYNFLAGS += -F /usr/lib/$(MACH64)/ld.so.1 -install: all $(ROOTFS_DYNLIB64) $(ROOTFS_LINKS64) $(ROOTFS_LINTLIB64) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) $(PICS) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/cmd/sgs/liblddbg/common/liblddbg.msg b/usr/src/cmd/sgs/liblddbg/common/liblddbg.msg index acf7fad9ba..558e1a3c28 100644 --- a/usr/src/cmd/sgs/liblddbg/common/liblddbg.msg +++ b/usr/src/cmd/sgs/liblddbg/common/liblddbg.msg @@ -1562,6 +1562,7 @@ @ MSG_CI_TLS_MODREM "TLS_MODREM" @ MSG_CI_TLS_STATMOD "TLS_STATMOD" @ MSG_CI_THRINIT "THRINIT" +@ MSG_CI_CRITICAL "CRITICAL" # TLS information flags diff --git a/usr/src/cmd/sgs/liblddbg/common/util.c b/usr/src/cmd/sgs/liblddbg/common/util.c index 04d669ebd1..02de483a82 100644 --- a/usr/src/cmd/sgs/liblddbg/common/util.c +++ b/usr/src/cmd/sgs/liblddbg/common/util.c @@ -290,7 +290,8 @@ static const Msg tags[] = { MSG_CI_TLS_MODADD, /* MSG_ORIG(MSG_CI_TLS_MODADD) */ MSG_CI_TLS_MODREM, /* MSG_ORIG(MSG_CI_TLS_MODREM) */ MSG_CI_TLS_STATMOD, /* MSG_ORIG(MSG_CI_TLS_STATMOD) */ - MSG_CI_THRINIT /* MSG_ORIG(MSG_CI_THRINIT) */ + MSG_CI_THRINIT, /* MSG_ORIG(MSG_CI_THRINIT) */ + MSG_CI_CRITICAL /* MSG_ORIG(MSG_CI_CRITICAL) */ }; void diff --git a/usr/src/cmd/sgs/packages/common/SUNWonld-README b/usr/src/cmd/sgs/packages/common/SUNWonld-README index d7c897c6c4..b46a2806c5 100644 --- a/usr/src/cmd/sgs/packages/common/SUNWonld-README +++ b/usr/src/cmd/sgs/packages/common/SUNWonld-README @@ -1475,3 +1475,6 @@ Bugid Risk Synopsis 6577982 ld.so.1 calls getpid() before it should when any LD_* are set 6826513 ldd gets confused by a crle(1) LD_PRELOAD setting 6831285 linker LD_DEBUG support needs improvements +6806791 filter builds could be optimized (link-editor components only) +6823371 calloc() uses suboptimal memset() causing 15% regression in SpecCPU2006 + gcc code (link-editor components only) diff --git a/usr/src/cmd/sgs/rtld/common/_rtld.h b/usr/src/cmd/sgs/rtld/common/_rtld.h index ff9589dd16..aa3355ffa0 100644 --- a/usr/src/cmd/sgs/rtld/common/_rtld.h +++ b/usr/src/cmd/sgs/rtld/common/_rtld.h @@ -690,6 +690,7 @@ extern void remove_lml(Lm_list *); extern void remove_plist(Alist **, int); extern void remove_so(Lm_list *, Rt_map *); extern int rt_cond_wait(Rt_cond *, Rt_lock *); +extern int rt_critical(void); extern int rt_bind_guard(int); extern int rt_bind_clear(int); extern int rt_get_extern(Lm_list *, Rt_map *); diff --git a/usr/src/cmd/sgs/rtld/common/audit.c b/usr/src/cmd/sgs/rtld/common/audit.c index 4415ea082f..87a18b89ca 100644 --- a/usr/src/cmd/sgs/rtld/common/audit.c +++ b/usr/src/cmd/sgs/rtld/common/audit.c @@ -116,6 +116,9 @@ audit_objfilter(Rt_map *frlmp, const char *ref, Rt_map *felmp, uint_t flags) { int appl = 0, respond = 1; + if (rt_critical()) + return (respond); + if ((rtld_flags & RT_FL_APPLIC) == 0) appl = rtld_flags |= RT_FL_APPLIC; @@ -171,6 +174,9 @@ audit_objsearch(Rt_map *clmp, const char *name, uint_t flags) char *nname = (char *)name; int appl = 0; + if (rt_critical()) + return (nname); + if ((rtld_flags & RT_FL_APPLIC) == 0) appl = rtld_flags |= RT_FL_APPLIC; @@ -247,6 +253,9 @@ audit_activity(Rt_map *clmp, uint_t flags) { int appl = 0; + if (rt_critical()) + return; + if ((rtld_flags & RT_FL_APPLIC) == 0) appl = rtld_flags |= RT_FL_APPLIC; @@ -335,6 +344,9 @@ audit_objopen(Rt_map *clmp, Rt_map *nlmp) uint_t clients = 0; Audit_info *aip; + if (rt_critical()) + return (respond); + /* * Determine the total number of audit libraries in use. This provides * the number of client structures required for this object. @@ -416,6 +428,9 @@ audit_objclose(Rt_map *clmp, Rt_map *lmp) { int appl = 0; + if (rt_critical()) + return; + if ((rtld_flags & RT_FL_APPLIC) == 0) appl = rtld_flags |= RT_FL_APPLIC; @@ -489,6 +504,9 @@ audit_pltenter(Rt_map *rlmp, Rt_map *dlmp, Sym *sym, uint_t ndx, Sym _sym = *sym; int _appl = 0; + if (rt_critical()) + return (_sym.st_value); + /* * We're effectively entering ld.so.1 from user (glue) code. */ @@ -561,6 +579,9 @@ audit_pltexit(uintptr_t retval, Rt_map *rlmp, Rt_map *dlmp, Sym *sym, uintptr_t _retval = retval; int _appl = 0; + if (rt_critical()) + return (_retval); + /* * We're effectively entering ld.so.1 from user (glue) code. */ @@ -667,6 +688,9 @@ audit_symbind(Rt_map *rlmp, Rt_map *dlmp, Sym *sym, uint_t ndx, Addr value, _sym = *sym; _sym.st_value = value; + if (rt_critical()) + return (_sym.st_value); + #if !defined(_ELF64) _sym.st_name += (Word)STRTAB(dlmp); #endif @@ -723,6 +747,9 @@ audit_preinit(Rt_map *clmp) { int appl = 0; + if (rt_critical()) + return; + if ((rtld_flags & RT_FL_APPLIC) == 0) appl = rtld_flags |= RT_FL_APPLIC; diff --git a/usr/src/cmd/sgs/rtld/common/external.c b/usr/src/cmd/sgs/rtld/common/external.c index 709918c7b3..713a9d5be5 100644 --- a/usr/src/cmd/sgs/rtld/common/external.c +++ b/usr/src/cmd/sgs/rtld/common/external.c @@ -151,6 +151,15 @@ * this interface (and no longer relies on the INITFIRST flag - which * others have started to camp out on). * + * CI_VERSION == 5 (Solaris 11). + * Use of "protected" references within libc, so that symbols are + * pre-bound, and don't require ld.so.1 binding. This implementation + * protects libc's critical regions from being vectored to auditors. + * + * CI_VERSION == 6 (Solaris 11). + * Added the CI_CRITICAL handshake, to allow "mem*" family to be reexposed + * as "global", and thus be redirected to auxiliary filters. + * * Release summary: * * Solaris 8 CI_ATEXIT via _ld_libc() @@ -286,6 +295,7 @@ get_lcinterface(Rt_map *lmp, Lc_interface *funcs) case CI_BIND_GUARD: case CI_BIND_CLEAR: case CI_THR_SELF: + case CI_CRITICAL: /* * If the global vector is unset, or this is the primary * link-map, set the global vector. @@ -500,18 +510,34 @@ rt_thr_self() } int -rt_mutex_lock(Rt_lock * mp) +rt_mutex_lock(Rt_lock *mp) { return (_lwp_mutex_lock((lwp_mutex_t *)mp)); } int -rt_mutex_unlock(Rt_lock * mp) +rt_mutex_unlock(Rt_lock *mp) { return (_lwp_mutex_unlock((lwp_mutex_t *)mp)); } /* + * Test whether we're in a libc critical region. Certain function references, + * like the "mem*" family, might require binding. Although these functions can + * safely bind to auxiliary filtees, they should not be captured by auditors. + */ +int +rt_critical() +{ + int (*fptr)(void); + + if ((fptr = glcs[CI_CRITICAL].lc_un.lc_func) != NULL) + return ((*fptr)()); + + return (0); +} + +/* * Mutex interfaces to resolve references from any objects extracted from * libc_pic.a. Note, as ld.so.1 is essentially single threaded these can be * noops. diff --git a/usr/src/common/mapfiles/common/map.filter b/usr/src/common/mapfiles/common/map.filter index 1059b1b61d..a25edbac94 100644 --- a/usr/src/common/mapfiles/common/map.filter +++ b/usr/src/common/mapfiles/common/map.filter @@ -1,15 +1,12 @@ # -#ident "%Z%%M% %I% %E% SMI" -# -# Copyright 2005 Sun Microsystems, Inc. All rights reserved. +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -47,6 +44,9 @@ # The assignment of all allocatable sections to this segment insures that the # .dynamic, and any .data or .bss sections, become part of the text. Note that # the compiler has a habit of generating empty .data and .bss sections. +# +# Override the default alignment so that this single paged object can be mapped +# more flexibly. -filter = LOAD ?RX; +filter = LOAD ?RX A0x1000; filter : ?A; diff --git a/usr/src/lib/Makefile.filter.com b/usr/src/lib/Makefile.filter.com new file mode 100644 index 0000000000..ea1c708955 --- /dev/null +++ b/usr/src/lib/Makefile.filter.com @@ -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 2009 Sun Microsystems, Inc. All rights reserved. +# Use is subject to license terms. +# +# Makefile.filter.com and Makefile.filter.targ provide centralized Makefiles +# for driving the creation of standard shared object filters. This class of +# filter contains absolutely no implementation (code), instead associating all +# symbol definitions to an alternative shared object (filtee). +# +# Standard filters are commonly used to preserve previously documented system +# interfaces when moving symbol definitions from one library to another. They +# are analogous to the way symbolic links are used in the system to preserve +# well known file names. For example, the Unified Process Model folded threads +# processing into libc.so.1, and left standard filters /lib/lib[p]thread.so.1 +# in place. These filters are built under usr/src/lib/lib[p]thread, and serve +# as typical examples. +# +# A typical Makefile.com for building a standard filter library contains: +# +# % cat Makefile.com +# ... +# LIBRARY = libxxxx.a +# VERS = .1 +# +# include $(SRC)/lib/Makefile.rootfs (1) +# +# LIBS += $(LINTLIB) (2) +# DYNFLAGS += -F filtee (3) +# MAPFILEDIR = . (4) +# +# 1. Use Makefile.rootfs when destination is /lib (rather than /usr/lib). +# 2. Add LINTLIB when a lint library is produced. +# 3. Customize DYNFLAGS to indicate filtee name. +# 4. Change MAPFILEDIR if mapfiles are not under ../common. +# +# The typical use of Makefile.filter.com and Makefile.filter.targ is through +# inclusion from a standard filters machine specific Makefiles: +# +# % cat $(MACH)/Makefile +# ... +# include $(SRC)/lib/Makefile.filter.com +# include ../Makefile.com +# include (SRC)/lib/Makefile.lib.64 (1) +# +# DYNFLAGS += -h libyyyyy.so.1 (2) +# +# install all $(ROOT...... +# +# include $(SRC)/lib/Makefile.filter.targ +# +# 1. Use Makefile.lib.64 for 64-bit builds. +# 2. Customize DYNFLAGS for $MACH if necessary. +# + +include $(SRC)/lib/Makefile.lib + +# Define common flags, that override or append to Makefile.lib rules. + +DYNFLAGS += $(ZNODUMP) $(ZNOLDYNSYM) +LIBS = $(DYNLIB) +SRCDIR = ../common +MAPFILES += $(MAPFILE.FLT) diff --git a/usr/src/cmd/sgs/libdl/Makefile.targ b/usr/src/lib/Makefile.filter.targ index 95cc2d06bd..c13cab4565 100644 --- a/usr/src/cmd/sgs/libdl/Makefile.targ +++ b/usr/src/lib/Makefile.filter.targ @@ -19,22 +19,30 @@ # CDDL HEADER END # # -# 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" -# +# Makefile.filter.com and Makefile.filter.targ provide centralized Makefiles +# for driving the creation of filters. See Makefile.filter.com for usage. -$(ROOTFS_LIBDIR)/%: % - $(INS.file) -$(ETCLIBDIR)/%: % - $(INS.file) +# Override lint sources from Makefile.lib. -delete: - $(RM) $(DYNLIB) +$(LINTLIB) := SRCS = $(SRCDIR)/$(LINTSRC) -include $(SRC)/lib/Makefile.targ -include $(SRC)/cmd/sgs/Makefile.targ +# Override shared object build rule from Makefile.lib. This rule uses $(LD) +# directly to avoid .init and .fini sections being added. + +BUILD.SO = $(LD) $(MAPFILECLASS) -o $@ -G $(DYNFLAGS) + +# Since no OBJECTS are used in this build, turn off CTF. + +CTFMERGE_LIB = : -lint: $(LINTLIB) $(SGSLINTOUT) +.KEEP_STATE: + +all: $$(LIBS) + +lint: + +include $(SRC)/lib/Makefile.targ diff --git a/usr/src/lib/Makefile.lib b/usr/src/lib/Makefile.lib index a998929ea5..5e28b0d25c 100644 --- a/usr/src/lib/Makefile.lib +++ b/usr/src/lib/Makefile.lib @@ -18,7 +18,7 @@ # # 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. # # @@ -44,15 +44,16 @@ AWK= awk SRCDIR = .. # -# We define MAPFILES here for the benefit of most libraries, -# those that follow the convention of having source files and other -# common files in the $(SRCDIR) directory. Libraries that do not -# follow this convention must define MAPFILES for themselves. +# We define MAPFILES here for the benefit of most libraries, those that +# follow the convention of having source files and other common files +# in the $(SRCDIR) directory. Libraries that do not follow this +# convention must define MAPFILES, or MAPFILEDIR for themselves. # Libraries that do follow this convention but that need supplemental # ISA-specific mapfiles can augment MAPFILES like this: # MAPFILES += mapfile-vers # -MAPFILES = $(SRCDIR)/mapfile-vers +MAPFILEDIR = $(SRCDIR) +MAPFILES = $(MAPFILEDIR)/mapfile-vers # # If HDRDIR is left unset, then it's possible for the $(ROOTHDRDIR)/% diff --git a/usr/src/lib/libaio/Makefile b/usr/src/lib/libaio/Makefile index 91de6ce168..6cb7a4fa8a 100644 --- a/usr/src/lib/libaio/Makefile +++ b/usr/src/lib/libaio/Makefile @@ -19,28 +19,24 @@ # CDDL HEADER END # # -# 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" -# -include ../Makefile.lib +include ../Makefile.lib -SUBDIRS = $(MACH) -$(BUILD64)SUBDIRS += $(MACH64) +SUBDIRS = $(MACH) $(BUILD64) $(MACH64) all := TARGET= all clean := TARGET= clean clobber := TARGET= clobber install := TARGET= install -lint := TARGET= lint .KEEP_STATE: all clean clobber install: $(SUBDIRS) -lint: $(SUBDIRS) +lint: $(SUBDIRS): FRC @cd $@; pwd; $(MAKE) $(TARGET) diff --git a/usr/src/lib/libaio/Makefile.com b/usr/src/lib/libaio/Makefile.com index 4f96d7e871..d43a344580 100644 --- a/usr/src/lib/libaio/Makefile.com +++ b/usr/src/lib/libaio/Makefile.com @@ -19,39 +19,15 @@ # CDDL HEADER END # # -# Copyright 2007 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" -# - -LIBRARY = libaio.a -VERS = .1 -include ../../Makefile.lib -include ../../Makefile.rootfs +LIBRARY = libaio.a +VERS = .1 -MAPFILES = mapfile-vers $(MAPFILE.FLT) +include $(SRC)/lib/Makefile.rootfs +LIBS += $(LINTLIB) DYNFLAGS += -F libc.so.1 - -LIBS = $(DYNLIB) $(LINTLIB) - -SRCDIR = ../common -$(LINTLIB) := SRCS = $(SRCDIR)/llib-laio - - -# Redefine shared object build rule to use $(LD) directly (this avoids .init -# and .fini sections being added). Also, since there are no OBJECTS, turn -# off CTF. - -BUILD.SO= $(LD) -o $@ -G $(DYNFLAGS) -CTFMERGE_LIB= : - -.KEEP_STATE: - -include ../../Makefile.targ - -all: $(LIBS) - -lint: +MAPFILEDIR = . # redirect mapfile-vers diff --git a/usr/src/lib/libaio/amd64/Makefile b/usr/src/lib/libaio/amd64/Makefile index 249f249362..70f0fc2457 100644 --- a/usr/src/lib/libaio/amd64/Makefile +++ b/usr/src/lib/libaio/amd64/Makefile @@ -19,15 +19,14 @@ # CDDL HEADER END # # -# 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" -# -include ../Makefile.com -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libaio/i386/Makefile b/usr/src/lib/libaio/i386/Makefile index b3157e385b..4e4e8c02a9 100644 --- a/usr/src/lib/libaio/i386/Makefile +++ b/usr/src/lib/libaio/i386/Makefile @@ -19,12 +19,13 @@ # CDDL HEADER END # # -# 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" -# -include ../Makefile.com +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com + +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libaio/sparc/Makefile b/usr/src/lib/libaio/sparc/Makefile index b3157e385b..4e4e8c02a9 100644 --- a/usr/src/lib/libaio/sparc/Makefile +++ b/usr/src/lib/libaio/sparc/Makefile @@ -19,12 +19,13 @@ # CDDL HEADER END # # -# 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" -# -include ../Makefile.com +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com + +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libaio/sparcv9/Makefile b/usr/src/lib/libaio/sparcv9/Makefile index 249f249362..70f0fc2457 100644 --- a/usr/src/lib/libaio/sparcv9/Makefile +++ b/usr/src/lib/libaio/sparcv9/Makefile @@ -19,15 +19,14 @@ # CDDL HEADER END # # -# 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" -# -include ../Makefile.com -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libc/amd64/mapfile-vers b/usr/src/lib/libc/amd64/mapfile-vers index 5cd5be235a..7c759736c1 100644 --- a/usr/src/lib/libc/amd64/mapfile-vers +++ b/usr/src/lib/libc/amd64/mapfile-vers @@ -107,6 +107,10 @@ SUNW_0.7 { malloc = NODIRECT; modf = FUNCTION FILTER libm.so.2; _modf = FUNCTION FILTER libm.so.2; + memcmp; + memcpy; + memmove; + memset; nextafter = FUNCTION FILTER libm.so.2; _nextafter = FUNCTION FILTER libm.so.2; _numeric; @@ -400,12 +404,8 @@ SUNW_0.7 { memccpy; _memccpy; memchr; - memcmp; memcntl; _memcntl; - memcpy; - memmove; - memset; mkdir; _mkdir; mkfifo; @@ -750,6 +750,10 @@ SUNWprivate_1.1 { _dlopen = FUNCTION FILTER /usr/lib/amd64/ld.so.1; _dlsym = FUNCTION FILTER /usr/lib/amd64/ld.so.1; _ld_libc = FUNCTION FILTER /usr/lib/amd64/ld.so.1; + _memcmp; + _memcpy; + _memmove; + _memset; protected: _D_cplx_lr_div; _D_cplx_lr_div_ix; @@ -759,10 +763,6 @@ SUNWprivate_1.1 { _F_cplx_lr_div_rx; __fltrounds; __fseterror_u; - _memcmp; - _memcpy; - _memmove; - _memset; sysi86; _sysi86; _X_cplx_div; diff --git a/usr/src/lib/libc/i386/mapfile-vers b/usr/src/lib/libc/i386/mapfile-vers index 019a4ba265..c54c1b3d14 100644 --- a/usr/src/lib/libc/i386/mapfile-vers +++ b/usr/src/lib/libc/i386/mapfile-vers @@ -285,6 +285,10 @@ SYSVABI_1.3 { ldexp = FUNCTION FILTER libm.so.2; logb = FUNCTION FILTER libm.so.2; malloc = NODIRECT; + memcmp; + memcpy; + memmove; + memset; modf = FUNCTION FILTER libm.so.2; _modf = FUNCTION FILTER libm.so.2; nextafter = FUNCTION FILTER libm.so.2; @@ -541,12 +545,8 @@ SYSVABI_1.3 { memccpy; _memccpy; memchr; - memcmp; memcntl; _memcntl; - memcpy; - memmove; - memset; mkdir; _mkdir; mkfifo; @@ -861,6 +861,10 @@ SUNWprivate_1.1 { _dlopen = FUNCTION FILTER /usr/lib/ld.so.1; _dlsym = FUNCTION FILTER /usr/lib/ld.so.1; _ld_libc = FUNCTION FILTER /usr/lib/ld.so.1; + _memcmp; + _memcpy; + _memmove; + _memset; _sse_hw; _sys_errlist; _sys_errs; @@ -885,10 +889,6 @@ SUNWprivate_1.1 { _fwscanf_c89; _imaxabs_c89; _imaxdiv_c89; - _memcmp; - _memcpy; - _memmove; - _memset; __moddi3; _printf_c89; _scanf_c89; diff --git a/usr/src/lib/libc/inc/libc_int.h b/usr/src/lib/libc/inc/libc_int.h index 3cb5be036d..940636b49c 100644 --- a/usr/src/lib/libc/inc/libc_int.h +++ b/usr/src/lib/libc/inc/libc_int.h @@ -20,15 +20,13 @@ */ /* - * Copyright 2008 Sun Microsystems, Inc. All rights reserved. + * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ #ifndef _LIBC_INT_H #define _LIBC_INT_H -#pragma ident "%Z%%M% %I% %E% SMI" - #ifdef __cplusplus extern "C" { #endif @@ -47,8 +45,9 @@ extern "C" { #define CI_TLS_MODREM 8 /* __tls_mod_remove() address */ #define CI_TLS_STATMOD 9 /* __tls_static_mods() address */ #define CI_THRINIT 10 /* libc thread initialization */ +#define CI_CRITICAL 11 /* critical level query interface */ -#define CI_MAX 11 +#define CI_MAX 12 #define CI_V_NONE 0 /* ci_version versions */ #define CI_V_ONE 1 /* original version */ @@ -56,8 +55,9 @@ extern "C" { #define CI_V_THREE 3 #define CI_V_FOUR 4 #define CI_V_FIVE 5 -#define CI_V_CURRENT CI_V_FIVE /* current version of libc interface */ -#define CI_V_NUM 6 /* number of CI_V_* numbers */ +#define CI_V_SIX 6 +#define CI_V_CURRENT CI_V_SIX /* current version of libc interface */ +#define CI_V_NUM 7 /* number of CI_V_* numbers */ /* * Flags for the bindguard routines. diff --git a/usr/src/lib/libc/inc/lint.h b/usr/src/lib/libc/inc/lint.h index d031a250c5..99a1d1ab83 100644 --- a/usr/src/lib/libc/inc/lint.h +++ b/usr/src/lib/libc/inc/lint.h @@ -20,15 +20,13 @@ */ /* - * Copyright 2008 Sun Microsystems, Inc. All rights reserved. + * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ #ifndef _LIBC_LINT_H #define _LIBC_LINT_H -#pragma ident "%Z%%M% %I% %E% SMI" - #ifdef __cplusplus extern "C" { #endif @@ -53,6 +51,33 @@ extern "C" { #define syscall _syscall6 #define __systemcall __systemcall6 +/* + * Shades of the old and deprecated "synonyms.h" file. + * Because of the awkward relationship between these functions: + * memcmp() + * memcpy() + * memmove() + * memset() + * and the sparc auxiliary filters: + * /platform/.../lib/libc_psr.so.1 + * we must be careful always to call the leading-underscore + * symbol names when calling from within libc itself. + * + * If an interposer interposes on these mem*() symbol names, + * and we call one of them from within a critical region in libc, + * we will end up in the interposer code while executing within + * the critical region. Chaos can ensue. + * + * We try to avoid this by calling only the leading-underscore names. + * We hope that no interposer will interpose on the leading-underscore + * versions of these functions, else all hope is lost. + */ + +#pragma redefine_extname memcmp _memcmp +#pragma redefine_extname memcpy _memcpy +#pragma redefine_extname memmove _memmove +#pragma redefine_extname memset _memset + #endif #ifdef __cplusplus diff --git a/usr/src/lib/libc/port/threads/thr.c b/usr/src/lib/libc/port/threads/thr.c index fdcf549f26..bfad10c06a 100644 --- a/usr/src/lib/libc/port/threads/thr.c +++ b/usr/src/lib/libc/port/threads/thr.c @@ -2191,8 +2191,8 @@ _ti_bind_guard(int flags) if ((self->ul_bindflags & bindflag) == bindflag) return (0); + self->ul_bindflags |= bindflag; if ((flags & (THR_FLG_NOLOCK | THR_FLG_REENTER)) == THR_FLG_NOLOCK) { - ASSERT(self->ul_critical == 0); sigoff(self); /* see no signals while holding ld_lock */ (void) mutex_lock(&udp->ld_lock); } @@ -2200,7 +2200,6 @@ _ti_bind_guard(int flags) self->ul_save_state = self->ul_cancel_disabled; self->ul_cancel_disabled = 1; set_cancel_pending_flag(self, 0); - self->ul_bindflags |= bindflag; return (1); } @@ -2218,7 +2217,6 @@ _ti_bind_clear(int flags) set_cancel_pending_flag(self, 0); exit_critical(self); if ((flags & (THR_FLG_NOLOCK | THR_FLG_REENTER)) == THR_FLG_NOLOCK) { - ASSERT(self->ul_critical == 0); if (MUTEX_OWNED(&udp->ld_lock, self)) { (void) mutex_unlock(&udp->ld_lock); sigon(self); /* reenable signals */ @@ -2228,6 +2226,21 @@ _ti_bind_clear(int flags) } /* + * Tell the dynamic linker (ld.so.1) whether or not it was entered from + * a critical region in libc. Return zero if not, else return non-zero. + */ +int +_ti_critical(void) +{ + ulwp_t *self = curthread; + int level = self->ul_critical; + + if ((self->ul_bindflags & THR_FLG_RTLD) == 0 || level == 0) + return (level); /* ld.so.1 hasn't (yet) called enter() */ + return (level - 1); +} + +/* * sigoff() and sigon() enable cond_wait() to behave (optionally) like * it does in the old libthread (see the comments in cond_wait_queue()). * Also, signals are deferred at thread startup until TLS constructors diff --git a/usr/src/lib/libc/port/threads/thread_interface.c b/usr/src/lib/libc/port/threads/thread_interface.c index c4dc1964e7..0cfa07e89c 100644 --- a/usr/src/lib/libc/port/threads/thread_interface.c +++ b/usr/src/lib/libc/port/threads/thread_interface.c @@ -2,9 +2,8 @@ * CDDL HEADER START * * The contents of this file are subject to the terms of the - * Common Development and Distribution License, Version 1.0 only - * (the "License"). You may not use this file except in compliance - * with the License. + * 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. @@ -19,19 +18,19 @@ * * CDDL HEADER END */ + /* - * Copyright 1999-2003 Sun Microsystems, Inc. All rights reserved. + * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" - #include "lint.h" #include "thr_uberdata.h" extern int _ti_bind_guard(); extern int _ti_bind_clear(); extern int _ti_thr_self(); +extern int _ti_critical(); /* * This is the array of interface functions passed to @@ -42,5 +41,6 @@ const Lc_interface rtld_funcs[] = { {CI_BIND_GUARD, (int(*)())_ti_bind_guard}, {CI_BIND_CLEAR, (int(*)())_ti_bind_clear}, {CI_THR_SELF, (int(*)())_ti_thr_self}, + {CI_CRITICAL, (int(*)())_ti_critical}, {CI_NULL, (int(*)())NULL} }; diff --git a/usr/src/lib/libc/sparc/mapfile-vers-aux b/usr/src/lib/libc/sparc/mapfile-vers-aux index 5184d84744..9465efdfa6 100644 --- a/usr/src/lib/libc/sparc/mapfile-vers-aux +++ b/usr/src/lib/libc/sparc/mapfile-vers-aux @@ -38,7 +38,7 @@ # SYSVABI_1.3 { - protected: + global: memcmp = AUXILIARY /platform/$PLATFORM/lib/libc_psr.so.1; memcpy = AUXILIARY /platform/$PLATFORM/lib/libc_psr.so.1; memmove = AUXILIARY /platform/$PLATFORM/lib/libc_psr.so.1; @@ -46,7 +46,7 @@ SYSVABI_1.3 { }; SUNWprivate_1.1 { - protected: + global: _memcmp = AUXILIARY /platform/$PLATFORM/lib/libc_psr.so.1; _memcpy = AUXILIARY /platform/$PLATFORM/lib/libc_psr.so.1; _memcpy = NODYNSORT; diff --git a/usr/src/lib/libc/sparc_hwcap1/sparc/mapfile-vers-aux b/usr/src/lib/libc/sparc_hwcap1/sparc/mapfile-vers-aux index 1f7d3269c4..b9a85d01db 100644 --- a/usr/src/lib/libc/sparc_hwcap1/sparc/mapfile-vers-aux +++ b/usr/src/lib/libc/sparc_hwcap1/sparc/mapfile-vers-aux @@ -38,7 +38,7 @@ # SYSVABI_1.3 { - protected: + global: memcmp; memcpy; memmove; @@ -46,7 +46,7 @@ SYSVABI_1.3 { }; SUNWprivate_1.1 { - protected: + global: _memcmp; _memcpy = NODYNSORT; _memmove; diff --git a/usr/src/lib/libc/sparc_hwcap1/sparcv9/mapfile-vers-aux b/usr/src/lib/libc/sparc_hwcap1/sparcv9/mapfile-vers-aux index 821f767d1b..001d2feeb9 100644 --- a/usr/src/lib/libc/sparc_hwcap1/sparcv9/mapfile-vers-aux +++ b/usr/src/lib/libc/sparc_hwcap1/sparcv9/mapfile-vers-aux @@ -38,7 +38,7 @@ # SUNW_0.7 { - protected: + global: memcmp; memcpy; memmove; @@ -46,7 +46,7 @@ SUNW_0.7 { }; SUNWprivate_1.1 { - protected: + global: _memcmp; _memcpy = NODYNSORT; _memmove; diff --git a/usr/src/lib/libc/sparcv9/mapfile-vers-aux b/usr/src/lib/libc/sparcv9/mapfile-vers-aux index 5fca166609..9c1bd8aca8 100644 --- a/usr/src/lib/libc/sparcv9/mapfile-vers-aux +++ b/usr/src/lib/libc/sparcv9/mapfile-vers-aux @@ -38,7 +38,7 @@ # SUNW_0.7 { - protected: + global: memcmp = AUXILIARY /platform/$PLATFORM/lib/sparcv9/libc_psr.so.1; memcpy = AUXILIARY /platform/$PLATFORM/lib/sparcv9/libc_psr.so.1; memmove = AUXILIARY /platform/$PLATFORM/lib/sparcv9/libc_psr.so.1; @@ -46,7 +46,7 @@ SUNW_0.7 { }; SUNWprivate_1.1 { - protected: + global: _memcmp = AUXILIARY /platform/$PLATFORM/lib/sparcv9/libc_psr.so.1; _memcpy = AUXILIARY /platform/$PLATFORM/lib/sparcv9/libc_psr.so.1; _memcpy = NODYNSORT; diff --git a/usr/src/lib/libdoor/Makefile b/usr/src/lib/libdoor/Makefile index edf046186f..6cb7a4fa8a 100644 --- a/usr/src/lib/libdoor/Makefile +++ b/usr/src/lib/libdoor/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,26 +19,24 @@ # CDDL HEADER END # # -# Copyright 2005 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.lib +include ../Makefile.lib -SUBDIRS = $(MACH) -$(BUILD64)SUBDIRS += $(MACH64) +SUBDIRS = $(MACH) $(BUILD64) $(MACH64) all := TARGET= all clean := TARGET= clean clobber := TARGET= clobber install := TARGET= install -lint := TARGET= lint .KEEP_STATE: -all clean clobber lint install: $(SUBDIRS) +all clean clobber install: $(SUBDIRS) + +lint: $(SUBDIRS): FRC @cd $@; pwd; $(MAKE) $(TARGET) diff --git a/usr/src/lib/libdoor/Makefile.com b/usr/src/lib/libdoor/Makefile.com index 284d1b49e4..75dbfa358b 100644 --- a/usr/src/lib/libdoor/Makefile.com +++ b/usr/src/lib/libdoor/Makefile.com @@ -19,39 +19,14 @@ # CDDL HEADER END # # -# Copyright 2007 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" -# - -LIBRARY = libdoor.a -VERS = .1 -include ../../Makefile.lib -include ../../Makefile.rootfs +LIBRARY = libdoor.a +VERS = .1 -MAPFILES += $(MAPFILE.FLT) +include $(SRC)/lib/Makefile.rootfs +LIBS += $(LINTLIB) DYNFLAGS += -F libc.so.1 - -LIBS = $(DYNLIB) $(LINTLIB) - -SRCDIR = ../common -$(LINTLIB) := SRCS = $(SRCDIR)/llib-ldoor - - -# Redefine shared object build rule to use $(LD) directly (this avoids .init -# and .fini sections being added). Also, since there are no OBJECTS, turn -# off CTF. - -BUILD.SO= $(LD) -o $@ -G $(DYNFLAGS) -CTFMERGE_LIB= : - -.KEEP_STATE: - -include ../../Makefile.targ - -all: $(LIBS) - -lint: diff --git a/usr/src/lib/libdoor/amd64/Makefile b/usr/src/lib/libdoor/amd64/Makefile index 3caee6ff32..70f0fc2457 100644 --- a/usr/src/lib/libdoor/amd64/Makefile +++ b/usr/src/lib/libdoor/amd64/Makefile @@ -19,21 +19,14 @@ # CDDL HEADER END # # -# 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" -# - -include ../Makefile.com -include ../../Makefile.lib.64 - -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) - -LIBS = $(DYNLIB) $(LINTLIB) -.KEEP_STATE: +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -all: $(LIBS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libdoor/i386/Makefile b/usr/src/lib/libdoor/i386/Makefile index 2a944b0b43..4e4e8c02a9 100644 --- a/usr/src/lib/libdoor/i386/Makefile +++ b/usr/src/lib/libdoor/i386/Makefile @@ -19,16 +19,13 @@ # CDDL HEADER END # # -# 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" -# - -include ../Makefile.com -.KEEP_STATE: +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com -all: $(LIBS) +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libdoor/sparc/Makefile b/usr/src/lib/libdoor/sparc/Makefile index 2a944b0b43..4e4e8c02a9 100644 --- a/usr/src/lib/libdoor/sparc/Makefile +++ b/usr/src/lib/libdoor/sparc/Makefile @@ -19,16 +19,13 @@ # CDDL HEADER END # # -# 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" -# - -include ../Makefile.com -.KEEP_STATE: +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com -all: $(LIBS) +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libdoor/sparcv9/Makefile b/usr/src/lib/libdoor/sparcv9/Makefile index 3caee6ff32..70f0fc2457 100644 --- a/usr/src/lib/libdoor/sparcv9/Makefile +++ b/usr/src/lib/libdoor/sparcv9/Makefile @@ -19,21 +19,14 @@ # CDDL HEADER END # # -# 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" -# - -include ../Makefile.com -include ../../Makefile.lib.64 - -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) - -LIBS = $(DYNLIB) $(LINTLIB) -.KEEP_STATE: +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -all: $(LIBS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libintl/Makefile b/usr/src/lib/libintl/Makefile index e49536d662..6cb7a4fa8a 100644 --- a/usr/src/lib/libintl/Makefile +++ b/usr/src/lib/libintl/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,26 +19,26 @@ # CDDL HEADER END # # -# Copyright 2003 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.lib -SUBDIRS= $(MACH) $(BUILD64) $(MACH64) +SUBDIRS = $(MACH) $(BUILD64) $(MACH64) -all := TARGET= all -clean := TARGET= clean -clobber := TARGET= clobber -install := TARGET= install -lint := TARGET= lint +all := TARGET= all +clean := TARGET= clean +clobber := TARGET= clobber +install := TARGET= install .KEEP_STATE: -all clean clobber install lint: $(SUBDIRS) +all clean clobber install: $(SUBDIRS) -$(MACH) $(MACH64): FRC - @cd $@; pwd; $(MAKE) $(TARGET) +lint: + +$(SUBDIRS): FRC + @cd $@; pwd; $(MAKE) $(TARGET) FRC: diff --git a/usr/src/lib/libintl/Makefile.com b/usr/src/lib/libintl/Makefile.com index a01dc6772e..78ac289513 100644 --- a/usr/src/lib/libintl/Makefile.com +++ b/usr/src/lib/libintl/Makefile.com @@ -19,36 +19,14 @@ # CDDL HEADER END # # -# Copyright 2007 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" -# - -LIBRARY= libintl.a -VERS= .1 - -include ../../Makefile.lib -include ../../Makefile.rootfs -MAPFILES += $(MAPFILE.FLT) +LIBRARY = libintl.a +VERS = .1 -SRCDIR= ../common +include $(SRC)/lib/Makefile.rootfs +LIBS += $(LINTLIB) DYNFLAGS += -F libc.so.1 - -LIBS= $(DYNLIB) $(LINTLIB) -$(LINTLIB):= SRCS=$(SRCDIR)/$(LINTSRC) - -# Redefine shared object build rule to use $(LD) directly (this avoids .init -# and .fini sections being added). Also, since there are no OBJECTS, turn -# off CTF. - -BUILD.SO= $(LD) -o $@ -G $(DYNFLAGS) -CTFMERGE_LIB= : - -all: $(LIBS) - -lint: - -include ../../Makefile.targ diff --git a/usr/src/lib/libintl/amd64/Makefile b/usr/src/lib/libintl/amd64/Makefile index 2937ace6dc..70f0fc2457 100644 --- a/usr/src/lib/libintl/amd64/Makefile +++ b/usr/src/lib/libintl/amd64/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,19 +19,14 @@ # CDDL HEADER END # # -# Copyright 2004 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com -include ../../Makefile.lib.64 - -.KEEP_STATE: - -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +include $(SRC)/lib/Makefile.lib.64 -all: $(LIBS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBS64) $(ROOTLINKS64) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libintl/i386/Makefile b/usr/src/lib/libintl/i386/Makefile index cba73d03de..4e4e8c02a9 100644 --- a/usr/src/lib/libintl/i386/Makefile +++ b/usr/src/lib/libintl/i386/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,12 +19,13 @@ # CDDL HEADER END # # -# Copyright 2004 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com -install: all $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) + +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libintl/sparc/Makefile b/usr/src/lib/libintl/sparc/Makefile index cba73d03de..4e4e8c02a9 100644 --- a/usr/src/lib/libintl/sparc/Makefile +++ b/usr/src/lib/libintl/sparc/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,12 +19,13 @@ # CDDL HEADER END # # -# Copyright 2004 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com -install: all $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) + +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libintl/sparcv9/Makefile b/usr/src/lib/libintl/sparcv9/Makefile index e1034e284a..70f0fc2457 100644 --- a/usr/src/lib/libintl/sparcv9/Makefile +++ b/usr/src/lib/libintl/sparcv9/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,15 +19,14 @@ # CDDL HEADER END # # -# Copyright 2004 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBS64) $(ROOTLINKS64) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libkrb5/Makefile b/usr/src/lib/libkrb5/Makefile index 3ee7c85c04..68feb56d99 100755..100644 --- a/usr/src/lib/libkrb5/Makefile +++ b/usr/src/lib/libkrb5/Makefile @@ -19,52 +19,45 @@ # CDDL HEADER END # # -# 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" -# - -include $(SRC)/lib/Makefile.lib -SUBDIRS= $(MACH) $(MACH64) +include ../Makefile.lib -INSTALLED_HDRS= com_err.h krb5.h -COMERRH= $(SRC)/lib/gss_mechs/mech_krb5/include/com_err.h -KRB5H= $(SRC)/uts/common/gssapi/mechs/krb5/include/krb5.h +SUBDIRS = $(MACH) $(BUILD64) $(MACH64) -KRB5INCDIR= $(ROOT)/usr/include/kerberosv5 +INSTALLED_HDRS = \ + com_err.h krb5.h +COMERRH = $(SRC)/lib/gss_mechs/mech_krb5/include/com_err.h +KRB5H = $(SRC)/uts/common/gssapi/mechs/krb5/include/krb5.h +KRB5INCDIR= $(ROOT)/usr/include/kerberosv5 -COMERRHINST= $(KRB5INCDIR)/com_err.h -KRB5HINST= $(KRB5INCDIR)/krb5.h - -KRB5HDRS= $(INSTALLED_HDRS:%=$(KRB5INCDIR)/%) +COMERRHINST = $(KRB5INCDIR)/com_err.h +KRB5HINST = $(KRB5INCDIR)/krb5.h +KRB5HDRS = $(INSTALLED_HDRS:%=$(KRB5INCDIR)/%) all := TARGET= all clean := TARGET= clean clobber := TARGET= clobber install := TARGET= install -lint := TARGET= lint - -LIBRARY= libkrb5.a .KEEP_STATE: -all clean clobber install lint: $(SUBDIRS) +all clean clobber install: $(SUBDIRS) -$(SUBDIRS): FRC - @cd $@; pwd; $(MAKE) $(TARGET) +lint check: +$(SUBDIRS): FRC + @cd $@; pwd; $(MAKE) $(TARGET) -install_h: $(KRB5INCDIR) $(KRB5HDRS) +install_h: $(KRB5INCDIR) $(KRB5HDRS) -$(COMERRHINST): $(COMERRH) +$(COMERRHINST): $(COMERRH) install -s -m 644 -f $(KRB5INCDIR) $(COMERRH) -$(KRB5HINST): $(KRB5H) +$(KRB5HINST): $(KRB5H) install -s -m 644 -f $(KRB5INCDIR) $(KRB5H) - -check FRC: - +FRC: diff --git a/usr/src/lib/libkrb5/Makefile.com b/usr/src/lib/libkrb5/Makefile.com index d7e596cd00..b5635c835b 100755..100644 --- a/usr/src/lib/libkrb5/Makefile.com +++ b/usr/src/lib/libkrb5/Makefile.com @@ -19,53 +19,11 @@ # CDDL HEADER END # # -# Copyright 2007 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 library definitions -include $(SRC)/lib/Makefile.lib LIBRARY = libkrb5.a -LLIBRARY = libkrb5.so.1 VERS = .1 -MAPFILES = ../common/mapfile $(MAPFILE.FLT) - -DYNFLAGS += -G $(ZLOADFLTR) - -LIBS = $(DYNLIB) - -#override liblink -INS.liblink= -$(RM) $@; $(SYMLINK) $(LIBLINKS)$(VERS) $@ - -.KEEP_STATE: - -all: $(LIBS) - -$(LIBS): $(MAPFILES) - $(LD) $(DYNFLAGS) -o $@ - - -$(ROOTLIBDIR)/$(DYNLIB) := FILEMODE= 755 -$(ROOTLIBDIR64)/$(DYNLIB) := FILEMODE= 755 - -$(ROOTLIBDIR)/%: % - $(INS.file) -$(ROOTLIBDIR64)/%: % - $(INS.file) - -$(ROOTLIBDIR)/$(LIBLINKS): $(ROOTLIBDIR)/$(LIBLINKS)$(VERS) - $(INS.liblink) -$(ROOTLIBDIR64)/$(LIBLINKS): $(ROOTLIBDIR64)/$(LIBLINKS)$(VERS) - $(INS.liblink64) - -clobber: clean - -$(RM) $(CLOBBERTARGFILES) - -clean: - -$(RM) $(LIBS) - -lint: +DYNFLAGS += $(ZLOADFLTR) diff --git a/usr/src/lib/libkrb5/amd64/Makefile b/usr/src/lib/libkrb5/amd64/Makefile index 8cb76d200d..1ca72d8fc1 100644 --- a/usr/src/lib/libkrb5/amd64/Makefile +++ b/usr/src/lib/libkrb5/amd64/Makefile @@ -19,14 +19,16 @@ # CDDL HEADER END # # -# Copyright 2007 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 + +DYNFLAGS += -R/usr/lib/64/gss -DYNFLAGS += -64 -R/usr/lib/64/gss +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libkrb5/common/mapfile b/usr/src/lib/libkrb5/common/mapfile-vers index abd3d255a8..abd3d255a8 100644 --- a/usr/src/lib/libkrb5/common/mapfile +++ b/usr/src/lib/libkrb5/common/mapfile-vers diff --git a/usr/src/lib/libkrb5/i386/Makefile b/usr/src/lib/libkrb5/i386/Makefile index d53a981575..56164b6fca 100755..100644 --- a/usr/src/lib/libkrb5/i386/Makefile +++ b/usr/src/lib/libkrb5/i386/Makefile @@ -19,14 +19,15 @@ # CDDL HEADER END # # -# Copyright 2007 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com DYNFLAGS += -R/usr/lib/gss -install: all $(ROOTLIBDIR) $(ROOTLIBS) $(ROOTLINKS) +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) + +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libkrb5/sparc/Makefile b/usr/src/lib/libkrb5/sparc/Makefile index d53a981575..56164b6fca 100755..100644 --- a/usr/src/lib/libkrb5/sparc/Makefile +++ b/usr/src/lib/libkrb5/sparc/Makefile @@ -19,14 +19,15 @@ # CDDL HEADER END # # -# Copyright 2007 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com DYNFLAGS += -R/usr/lib/gss -install: all $(ROOTLIBDIR) $(ROOTLIBS) $(ROOTLINKS) +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) + +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libkrb5/sparcv9/Makefile b/usr/src/lib/libkrb5/sparcv9/Makefile index 8cb76d200d..1ca72d8fc1 100755..100644 --- a/usr/src/lib/libkrb5/sparcv9/Makefile +++ b/usr/src/lib/libkrb5/sparcv9/Makefile @@ -19,14 +19,16 @@ # CDDL HEADER END # # -# Copyright 2007 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 + +DYNFLAGS += -R/usr/lib/64/gss -DYNFLAGS += -64 -R/usr/lib/64/gss +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libmd5/Makefile b/usr/src/lib/libmd5/Makefile index 71408594af..6cb7a4fa8a 100644 --- a/usr/src/lib/libmd5/Makefile +++ b/usr/src/lib/libmd5/Makefile @@ -19,28 +19,24 @@ # CDDL HEADER END # # -# 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" -# -include $(SRC)/Makefile.master +include ../Makefile.lib -SUBDIRS= $(MACH) -$(BUILD64)SUBDIRS += $(MACH64) +SUBDIRS = $(MACH) $(BUILD64) $(MACH64) all := TARGET= all clean := TARGET= clean clobber := TARGET= clobber install := TARGET= install -lint := TARGET= lint .KEEP_STATE: -.PARALLEL: $(MACH) $(MACH64) +all clean clobber install: $(SUBDIRS) -all clean clobber install lint: $(SUBDIRS) +lint: $(SUBDIRS): FRC @cd $@; pwd; $(MAKE) $(TARGET) diff --git a/usr/src/lib/libmd5/Makefile.com b/usr/src/lib/libmd5/Makefile.com index 16f4f6dc7b..856d8d9cce 100644 --- a/usr/src/lib/libmd5/Makefile.com +++ b/usr/src/lib/libmd5/Makefile.com @@ -19,38 +19,14 @@ # CDDL HEADER END # # -# Copyright 2007 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" -# - -LIBRARY= libmd5.a -VERS= .1 - -include ../../Makefile.lib -include ../../Makefile.rootfs - -DYNFLAGS += -F libmd.so.1 - -LIBS = $(DYNLIB) $(LINTLIB) - -SRCDIR = ../common -$(LINTLIB) := SRCS = $(SRCDIR)/llib-lmd5 - -MAPFILES += $(MAPFILE.FLT) - -# Redefine shared object build rule to use $(LD) directly (this avoids .init -# and .fini sections being added). Also, since there are no OBJECTS, turn -# off CTF. - -BUILD.SO= $(LD) -o $@ -G $(DYNFLAGS) -CTFMERGE_LIB= : - -.KEEP_STATE: -all: $(LIBS) +LIBRARY = libmd5.a +VERS = .1 -lint: +include $(SRC)/lib/Makefile.rootfs -include ../../Makefile.targ +LIBS += $(LINTLIB) +DYNFLAGS += -F libmd.so.1 diff --git a/usr/src/lib/libmd5/amd64/Makefile b/usr/src/lib/libmd5/amd64/Makefile index bb52c69dfe..70f0fc2457 100644 --- a/usr/src/lib/libmd5/amd64/Makefile +++ b/usr/src/lib/libmd5/amd64/Makefile @@ -19,17 +19,14 @@ # CDDL HEADER END # # -# 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" -# -# lib/libmd5/amd64/Makefile -# -include ../Makefile.com -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libmd5/i386/Makefile b/usr/src/lib/libmd5/i386/Makefile index a333224278..4e4e8c02a9 100644 --- a/usr/src/lib/libmd5/i386/Makefile +++ b/usr/src/lib/libmd5/i386/Makefile @@ -19,12 +19,13 @@ # CDDL HEADER END # # -# 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" -# -include ../Makefile.com +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com + +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libmd5/inc.flg b/usr/src/lib/libmd5/inc.flg deleted file mode 100644 index bee518812f..0000000000 --- a/usr/src/lib/libmd5/inc.flg +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/sh -# -# CDDL HEADER START -# -# The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (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 2003 Sun Microsystems, Inc. All rights reserved. -# Use is subject to license terms. -# -#ident "%Z%%M% %I% %E% SMI" - -find_files "s.*" usr/src/common/crypto/md5 diff --git a/usr/src/lib/libmd5/sparc/Makefile b/usr/src/lib/libmd5/sparc/Makefile index 16ccc40281..4e4e8c02a9 100644 --- a/usr/src/lib/libmd5/sparc/Makefile +++ b/usr/src/lib/libmd5/sparc/Makefile @@ -19,14 +19,13 @@ # CDDL HEADER END # # -# 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" -# -# lib/libmd5/sparc/Makefile -# -include ../Makefile.com +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com + +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libmd5/sparcv9/Makefile b/usr/src/lib/libmd5/sparcv9/Makefile index 5e5b3dc6ab..70f0fc2457 100644 --- a/usr/src/lib/libmd5/sparcv9/Makefile +++ b/usr/src/lib/libmd5/sparcv9/Makefile @@ -19,17 +19,14 @@ # CDDL HEADER END # # -# 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" -# -# lib/libmd5/sparcv9/Makefile -# -include ../Makefile.com -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libpthread/Makefile b/usr/src/lib/libpthread/Makefile index aaab771c04..6cb7a4fa8a 100644 --- a/usr/src/lib/libpthread/Makefile +++ b/usr/src/lib/libpthread/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,28 +19,24 @@ # CDDL HEADER END # # -# Copyright 1997-2003 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.lib +include ../Makefile.lib -SUBDIRS = $(MACH) -$(BUILD64)SUBDIRS += $(MACH64) +SUBDIRS = $(MACH) $(BUILD64) $(MACH64) all := TARGET= all clean := TARGET= clean clobber := TARGET= clobber install := TARGET= install -lint := TARGET= lint .KEEP_STATE: all clean clobber install: $(SUBDIRS) -lint: $(SUBDIRS) +lint: $(SUBDIRS): FRC @cd $@; pwd; $(MAKE) $(TARGET) diff --git a/usr/src/lib/libpthread/Makefile.com b/usr/src/lib/libpthread/Makefile.com index d943a84ff6..74cc5833ad 100644 --- a/usr/src/lib/libpthread/Makefile.com +++ b/usr/src/lib/libpthread/Makefile.com @@ -19,38 +19,15 @@ # CDDL HEADER END # # -# Copyright 2007 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" -# -LIBRARY = libpthread.a -VERS = .1 +LIBRARY = libpthread.a +VERS = .1 -include ../../Makefile.lib -include ../../Makefile.rootfs +include $(SRC)/lib/Makefile.rootfs +LIBS += $(LINTLIB) DYNFLAGS += -F libc.so.1 - -LIBS = $(DYNLIB) $(LINTLIB) - -SRCDIR = ../common -$(LINTLIB) := SRCS = $(SRCDIR)/llib-lpthread - -MAPFILES = mapfile-vers $(MAPFILE.FLT) - -# Redefine shared object build rule to use $(LD) directly (this avoids .init -# and .fini sections being added). Also, since there are no OBJECTS, turn -# off CTF. - -BUILD.SO= $(LD) -o $@ -G $(DYNFLAGS) -CTFMERGE_LIB= : - -.KEEP_STATE: - -include ../../Makefile.targ - -all: $(LIBS) - -lint: +MAPFILEDIR = . # redirect mapfile-vers diff --git a/usr/src/lib/libpthread/amd64/Makefile b/usr/src/lib/libpthread/amd64/Makefile index 9c1d6cf6cd..70f0fc2457 100644 --- a/usr/src/lib/libpthread/amd64/Makefile +++ b/usr/src/lib/libpthread/amd64/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,15 +19,14 @@ # CDDL HEADER END # # -# Copyright 2004 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 -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libpthread/i386/Makefile b/usr/src/lib/libpthread/i386/Makefile index 5a6c1eeff6..4e4e8c02a9 100644 --- a/usr/src/lib/libpthread/i386/Makefile +++ b/usr/src/lib/libpthread/i386/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,12 +19,13 @@ # CDDL HEADER END # # -# Copyright 2004 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 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com + +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libpthread/sparc/Makefile b/usr/src/lib/libpthread/sparc/Makefile index 5a6c1eeff6..4e4e8c02a9 100644 --- a/usr/src/lib/libpthread/sparc/Makefile +++ b/usr/src/lib/libpthread/sparc/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,12 +19,13 @@ # CDDL HEADER END # # -# Copyright 2004 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 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com + +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libpthread/sparcv9/Makefile b/usr/src/lib/libpthread/sparcv9/Makefile index 9c1d6cf6cd..70f0fc2457 100644 --- a/usr/src/lib/libpthread/sparcv9/Makefile +++ b/usr/src/lib/libpthread/sparcv9/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,15 +19,14 @@ # CDDL HEADER END # # -# Copyright 2004 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 -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/librt/Makefile b/usr/src/lib/librt/Makefile index 91de6ce168..6cb7a4fa8a 100644 --- a/usr/src/lib/librt/Makefile +++ b/usr/src/lib/librt/Makefile @@ -19,28 +19,24 @@ # CDDL HEADER END # # -# 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" -# -include ../Makefile.lib +include ../Makefile.lib -SUBDIRS = $(MACH) -$(BUILD64)SUBDIRS += $(MACH64) +SUBDIRS = $(MACH) $(BUILD64) $(MACH64) all := TARGET= all clean := TARGET= clean clobber := TARGET= clobber install := TARGET= install -lint := TARGET= lint .KEEP_STATE: all clean clobber install: $(SUBDIRS) -lint: $(SUBDIRS) +lint: $(SUBDIRS): FRC @cd $@; pwd; $(MAKE) $(TARGET) diff --git a/usr/src/lib/librt/Makefile.com b/usr/src/lib/librt/Makefile.com index bbaebd88c2..b66642374e 100644 --- a/usr/src/lib/librt/Makefile.com +++ b/usr/src/lib/librt/Makefile.com @@ -19,38 +19,15 @@ # CDDL HEADER END # # -# Copyright 2007 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" -# -LIBRARY = librt.a -VERS = .1 +LIBRARY = librt.a +VERS = .1 -include ../../Makefile.lib -include ../../Makefile.rootfs +include $(SRC)/lib/Makefile.rootfs +LIBS += $(LINTLIB) DYNFLAGS += -F libc.so.1 - -LIBS = $(DYNLIB) $(LINTLIB) - -SRCDIR = ../common -$(LINTLIB) := SRCS = $(SRCDIR)/llib-lrt - -MAPFILES = mapfile-vers $(MAPFILE.FLT) - -# Redefine shared object build rule to use $(LD) directly (this avoids .init -# and .fini sections being added). Also, since there are no OBJECTS, turn -# off CTF. - -BUILD.SO= $(LD) -o $@ -G $(DYNFLAGS) -CTFMERGE_LIB= : - -.KEEP_STATE: - -include ../../Makefile.targ - -all: $(LIBS) - -lint: +MAPFILEDIR = . # redirect mapfile-vers diff --git a/usr/src/lib/librt/amd64/Makefile b/usr/src/lib/librt/amd64/Makefile index 249f249362..70f0fc2457 100644 --- a/usr/src/lib/librt/amd64/Makefile +++ b/usr/src/lib/librt/amd64/Makefile @@ -19,15 +19,14 @@ # CDDL HEADER END # # -# 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" -# -include ../Makefile.com -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/librt/i386/Makefile b/usr/src/lib/librt/i386/Makefile index b3157e385b..4e4e8c02a9 100644 --- a/usr/src/lib/librt/i386/Makefile +++ b/usr/src/lib/librt/i386/Makefile @@ -19,12 +19,13 @@ # CDDL HEADER END # # -# 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" -# -include ../Makefile.com +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com + +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/librt/sparc/Makefile b/usr/src/lib/librt/sparc/Makefile index b3157e385b..4e4e8c02a9 100644 --- a/usr/src/lib/librt/sparc/Makefile +++ b/usr/src/lib/librt/sparc/Makefile @@ -19,12 +19,13 @@ # CDDL HEADER END # # -# 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" -# -include ../Makefile.com +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com + +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/librt/sparcv9/Makefile b/usr/src/lib/librt/sparcv9/Makefile index 249f249362..70f0fc2457 100644 --- a/usr/src/lib/librt/sparcv9/Makefile +++ b/usr/src/lib/librt/sparcv9/Makefile @@ -19,15 +19,14 @@ # CDDL HEADER END # # -# 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" -# -include ../Makefile.com -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libsched/Makefile b/usr/src/lib/libsched/Makefile index fca90360ad..6cb7a4fa8a 100644 --- a/usr/src/lib/libsched/Makefile +++ b/usr/src/lib/libsched/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,29 +19,26 @@ # CDDL HEADER END # # -# Copyright 2003 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" -# -# lib/libsched/Makefile include ../Makefile.lib -SUBDIRS= $(MACH) $(BUILD64) $(MACH64) +SUBDIRS = $(MACH) $(BUILD64) $(MACH64) all := TARGET= all clean := TARGET= clean clobber := TARGET= clobber install := TARGET= install -lint := TARGET= lint -package := TARGET= package .KEEP_STATE: -all clean clobber install lint package: $(SUBDIRS) +all clean clobber install: $(SUBDIRS) + +lint: -$(MACH) $(MACH64): FRC - @cd $@; pwd; $(MAKE) $(TARGET) +$(SUBDIRS): FRC + @cd $@; pwd; $(MAKE) $(TARGET) FRC: diff --git a/usr/src/lib/libsched/Makefile.com b/usr/src/lib/libsched/Makefile.com index 1e04a43ab2..44d5d8495e 100644 --- a/usr/src/lib/libsched/Makefile.com +++ b/usr/src/lib/libsched/Makefile.com @@ -19,37 +19,12 @@ # CDDL HEADER END # # -# Copyright 2007 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" -# LIBRARY = libsched.a VERS = .1 -include ../../Makefile.lib - -LIBS = $(DYNLIB) $(LINTLIB) -$(LINTLIB) := SRCS = ../common/llib-lsched - -SRCDIR= ../common - -MAPFILES += $(MAPFILE.FLT) - +LIBS += $(LINTLIB) DYNFLAGS += -F libc.so.1 - -# Redefine shared object build rule to use $(LD) directly (this avoids .init -# and .fini sections being added). Also, since there are no OBJECTS, turn -# off CTF. - -BUILD.SO= $(LD) -o $@ -G $(DYNFLAGS) -CTFMERGE_LIB= : - -.KEEP_STATE: - -all: $(LIBS) - -lint: - -include ../../Makefile.targ diff --git a/usr/src/lib/libsched/amd64/Makefile b/usr/src/lib/libsched/amd64/Makefile index ea25dc66bb..70f0fc2457 100644 --- a/usr/src/lib/libsched/amd64/Makefile +++ b/usr/src/lib/libsched/amd64/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,17 +19,14 @@ # CDDL HEADER END # # -# Copyright 2004 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com -include ../../Makefile.lib.64 - -.KEEP_STATE: +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libsched/i386/Makefile b/usr/src/lib/libsched/i386/Makefile index 9fda4db646..4e4e8c02a9 100644 --- a/usr/src/lib/libsched/i386/Makefile +++ b/usr/src/lib/libsched/i386/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,15 +19,13 @@ # CDDL HEADER END # # -# Copyright 2003 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" -# -# lib/libsched/i386/Makefile +include $(SRC)/lib/Makefile.filter.com include ../Makefile.com -.KEEP_STATE: +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libsched/sparc/Makefile b/usr/src/lib/libsched/sparc/Makefile index e3983a2f8f..4e4e8c02a9 100644 --- a/usr/src/lib/libsched/sparc/Makefile +++ b/usr/src/lib/libsched/sparc/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,15 +19,13 @@ # CDDL HEADER END # # -# Copyright 2003 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" -# -# lib/libsched/sparc/Makefile +include $(SRC)/lib/Makefile.filter.com include ../Makefile.com -.KEEP_STATE: +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libsched/sparcv9/Makefile b/usr/src/lib/libsched/sparcv9/Makefile index f3c75044e4..70f0fc2457 100644 --- a/usr/src/lib/libsched/sparcv9/Makefile +++ b/usr/src/lib/libsched/sparcv9/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,18 +19,14 @@ # CDDL HEADER END # # -# Copyright 2003 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" -# -# lib/libsched/sparcv9/Makefile +include $(SRC)/lib/Makefile.filter.com include ../Makefile.com -include ../../Makefile.lib.64 - -.KEEP_STATE: +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libsys/Makefile b/usr/src/lib/libsys/Makefile index a4b0682369..24f9ff465f 100644 --- a/usr/src/lib/libsys/Makefile +++ b/usr/src/lib/libsys/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,28 +19,26 @@ # CDDL HEADER END # # -# Copyright 2004 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.lib -SUBDIRS= $(MACH) +SUBDIRS = $(MACH) -all := TARGET= all -clean := TARGET= clean -clobber := TARGET= clobber -install := TARGET= install +all := TARGET= all +clean := TARGET= clean +clobber := TARGET= clobber +install := TARGET= install .KEEP_STATE: -all clean clobber install: $(SUBDIRS) +all clean clobber install: $(SUBDIRS) lint: $(SUBDIRS): FRC - @cd $@; pwd; $(MAKE) $(TARGET) + @cd $@; pwd; $(MAKE) $(TARGET) FRC: diff --git a/usr/src/lib/libsys/Makefile.com b/usr/src/lib/libsys/Makefile.com index c27219af5b..86630ea862 100644 --- a/usr/src/lib/libsys/Makefile.com +++ b/usr/src/lib/libsys/Makefile.com @@ -19,37 +19,20 @@ # CDDL HEADER END # # -# Copyright 2007 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" -# - -LIBRARY= libsys.a -VERS= .1 - -COMOBJ= libsys.o -OBJECTS= $(COMOBJ) $(MACHOBJ) -include ../../../lib/Makefile.lib - -MAPFILES = mapfile-vers $(MAPFILE.FLT) +LIBRARY = libsys.a +VERS = .1 # Define libsys to be a filter on libc. The ABI requires the runtime linker as # the soname. +SONAME = /usr/lib/ld.so.1 +DYNFLAGS += -F /usr/lib/libc.so.1 +MAPFILEDIR = . # redirect mapfile-vers -DYNFLAGS += -F/usr/lib/libc.so.1 - -SONAME= /usr/lib/ld.so.1 - -# Redefine shared object build rule to use $(LD) directly (this avoids .init -# and .fini sections being added). - -BUILD.SO= $(LD) -o $@ -G $(DYNFLAGS) $(PICS) - -pics/%.o := ASFLAGS += $(AS_PICFLAGS) - -COMSRC= $(COMOBJ:%.o=%.c) -MACHSRC= $(MACHOBJ:%.o=%.s) +COMSRC = $(COMOBJ:%.o=%.c) +MACHSRC = $(MACHOBJ:%.o=%.s) -CLOBBERFILES += $(DYNLIB) $(LIBLINKS) $(COMSRC) $(MACHSRC) +CLOBBERFILES += $(COMSRC) $(MACHSRC) diff --git a/usr/src/lib/libsys/Makefile.targ b/usr/src/lib/libsys/Makefile.targ index c78f09af6a..9738a9b9b6 100644 --- a/usr/src/lib/libsys/Makefile.targ +++ b/usr/src/lib/libsys/Makefile.targ @@ -19,20 +19,20 @@ # CDDL HEADER END # # -# 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" -# -pics/%.o: %.s - $(COMPILE.s) -o $@ $< - $(POST_PROCESS_O) +BUILD.SO += $(PICS) -pics/%.o: %.c - $(COMPILE.c) -o $@ $< - $(POST_PROCESS_O) +$(COMSRC): ../common/libsys.sh libsys.list + sh ../common/libsys.sh -include ../../../lib/Makefile.targ +$(MACHSRC): libsys.sh libsyss.list + sh ./libsys.sh -FRC: +pics/%.o := ASFLAGS += $(AS_PICFLAGS) + +pics/%.o: %.s + $(COMPILE.s) -o $@ $< + $(POST_PROCESS_O) diff --git a/usr/src/lib/libsys/i386/Makefile b/usr/src/lib/libsys/i386/Makefile index 683e01b9ce..6e0d26d1db 100644 --- a/usr/src/lib/libsys/i386/Makefile +++ b/usr/src/lib/libsys/i386/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,20 +19,19 @@ # CDDL HEADER END # # -# Copyright 2003 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 - -.KEEP_STATE: +# Define objects first to trigger $(PIC) rules in Makefile.lib -all: $(DYNLIB) +COMOBJ = libsys.o +OBJECTS = $(COMOBJ) -install: all $(ROOTDYNLIB) $(ROOTLINKS) +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com -$(COMSRC): ../common/libsys.sh libsys.list - sh ../common/libsys.sh +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) +include $(SRC)/lib/Makefile.filter.targ include ../Makefile.targ diff --git a/usr/src/lib/libsys/sparc/Makefile b/usr/src/lib/libsys/sparc/Makefile index bf5e296647..249cb75708 100644 --- a/usr/src/lib/libsys/sparc/Makefile +++ b/usr/src/lib/libsys/sparc/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,25 +19,20 @@ # CDDL HEADER END # # -# Copyright 2004 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" -MACHOBJ= libsyss.o +# Define objects first to trigger $(PIC) rules in Makefile.lib -include ../Makefile.com - -.KEEP_STATE: - -all: $(DYNLIB) +COMOBJ = libsys.o +MACHOBJ = libsyss.o +OBJECTS = $(COMOBJ) $(MACHOBJ) -install: all $(ROOTDYNLIB) $(ROOTLINKS) - -$(COMSRC): ../common/libsys.sh libsys.list - sh ../common/libsys.sh +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com -$(MACHSRC): libsys.sh libsyss.list - sh ./libsys.sh +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) +include $(SRC)/lib/Makefile.filter.targ include ../Makefile.targ diff --git a/usr/src/lib/libthread/Makefile b/usr/src/lib/libthread/Makefile index a6afdbbb90..6cb7a4fa8a 100644 --- a/usr/src/lib/libthread/Makefile +++ b/usr/src/lib/libthread/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,28 +19,24 @@ # CDDL HEADER END # # -# Copyright 1999-2003 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.lib +include ../Makefile.lib -SUBDIRS = $(MACH) -$(BUILD64)SUBDIRS += $(MACH64) +SUBDIRS = $(MACH) $(BUILD64) $(MACH64) all := TARGET= all clean := TARGET= clean clobber := TARGET= clobber install := TARGET= install -lint := TARGET= lint .KEEP_STATE: all clean clobber install: $(SUBDIRS) -lint: $(SUBDIRS) +lint: $(SUBDIRS): FRC @cd $@; pwd; $(MAKE) $(TARGET) diff --git a/usr/src/lib/libthread/Makefile.com b/usr/src/lib/libthread/Makefile.com index a8954595b7..ffde440e62 100644 --- a/usr/src/lib/libthread/Makefile.com +++ b/usr/src/lib/libthread/Makefile.com @@ -19,38 +19,15 @@ # CDDL HEADER END # # -# Copyright 2007 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" -# -LIBRARY = libthread.a -VERS = .1 +LIBRARY = libthread.a +VERS = .1 -include ../../Makefile.lib -include ../../Makefile.rootfs +include $(SRC)/lib/Makefile.rootfs +LIBS += $(LINTLIB) DYNFLAGS += -F libc.so.1 - -LIBS = $(DYNLIB) $(LINTLIB) - -SRCDIR = ../common -$(LINTLIB) := SRCS = $(SRCDIR)/llib-lthread - -MAPFILES = mapfile-vers $(MAPFILE.FLT) - -# Redefine shared object build rule to use $(LD) directly (this avoids .init -# and .fini sections being added). Also, since there are no OBJECTS, turn -# off CTF. - -BUILD.SO= $(LD) -o $@ -G $(DYNFLAGS) -CTFMERGE_LIB= : - -.KEEP_STATE: - -include ../../Makefile.targ - -all: $(LIBS) - -lint: +MAPFILEDIR = . # redirect mapfile-vers diff --git a/usr/src/lib/libthread/amd64/Makefile b/usr/src/lib/libthread/amd64/Makefile index 9c1d6cf6cd..70f0fc2457 100644 --- a/usr/src/lib/libthread/amd64/Makefile +++ b/usr/src/lib/libthread/amd64/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,15 +19,14 @@ # CDDL HEADER END # # -# Copyright 2004 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 -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libthread/i386/Makefile b/usr/src/lib/libthread/i386/Makefile index 5a6c1eeff6..4e4e8c02a9 100644 --- a/usr/src/lib/libthread/i386/Makefile +++ b/usr/src/lib/libthread/i386/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,12 +19,13 @@ # CDDL HEADER END # # -# Copyright 2004 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 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com + +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libthread/sparc/Makefile b/usr/src/lib/libthread/sparc/Makefile index 5a6c1eeff6..4e4e8c02a9 100644 --- a/usr/src/lib/libthread/sparc/Makefile +++ b/usr/src/lib/libthread/sparc/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,12 +19,13 @@ # CDDL HEADER END # # -# Copyright 2004 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 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com + +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libthread/sparcv9/Makefile b/usr/src/lib/libthread/sparcv9/Makefile index 9c1d6cf6cd..70f0fc2457 100644 --- a/usr/src/lib/libthread/sparcv9/Makefile +++ b/usr/src/lib/libthread/sparcv9/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,15 +19,14 @@ # CDDL HEADER END # # -# Copyright 2004 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 -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.filter.com +include ../Makefile.com +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libw/Makefile b/usr/src/lib/libw/Makefile index e49536d662..6cb7a4fa8a 100644 --- a/usr/src/lib/libw/Makefile +++ b/usr/src/lib/libw/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,26 +19,26 @@ # CDDL HEADER END # # -# Copyright 2003 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.lib -SUBDIRS= $(MACH) $(BUILD64) $(MACH64) +SUBDIRS = $(MACH) $(BUILD64) $(MACH64) -all := TARGET= all -clean := TARGET= clean -clobber := TARGET= clobber -install := TARGET= install -lint := TARGET= lint +all := TARGET= all +clean := TARGET= clean +clobber := TARGET= clobber +install := TARGET= install .KEEP_STATE: -all clean clobber install lint: $(SUBDIRS) +all clean clobber install: $(SUBDIRS) -$(MACH) $(MACH64): FRC - @cd $@; pwd; $(MAKE) $(TARGET) +lint: + +$(SUBDIRS): FRC + @cd $@; pwd; $(MAKE) $(TARGET) FRC: diff --git a/usr/src/lib/libw/Makefile.com b/usr/src/lib/libw/Makefile.com index 5e9c37aa0a..8b7cde6d48 100644 --- a/usr/src/lib/libw/Makefile.com +++ b/usr/src/lib/libw/Makefile.com @@ -19,35 +19,13 @@ # CDDL HEADER END # # -# Copyright 2007 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" -# - -LIBRARY= libw.a -VERS= .1 - -include ../../Makefile.lib -include ../../Makefile.rootfs -SRCDIR = ../common +LIBRARY = libw.a +VERS = .1 -MAPFILES += $(MAPFILE.FLT) +include $(SRC)/lib/Makefile.rootfs DYNFLAGS += -F libc.so.1 - -LIBS= $(DYNLIB) - -# Redefine shared object build rule to use $(LD) directly (this avoids .init -# and .fini sections being added). Also, since there are no OBJECTS, turn -# off CTF. - -BUILD.SO= $(LD) -o $@ -G $(DYNFLAGS) -CTFMERGE_LIB= : - -include ../../Makefile.targ - -all: $(LIBS) - -lint: diff --git a/usr/src/lib/libw/amd64/Makefile b/usr/src/lib/libw/amd64/Makefile index 0c09de3ef5..70f0fc2457 100644 --- a/usr/src/lib/libw/amd64/Makefile +++ b/usr/src/lib/libw/amd64/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,16 +19,14 @@ # CDDL HEADER END # # -# Copyright 2003 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -.KEEP_STATE: - -install: all $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libw/i386/Makefile b/usr/src/lib/libw/i386/Makefile index 0351e399ad..c318e6089b 100644 --- a/usr/src/lib/libw/i386/Makefile +++ b/usr/src/lib/libw/i386/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,13 +19,13 @@ # CDDL HEADER END # # -# Copyright 2003 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com -.KEEP_STATE: +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) -install: all $(ROOTLIBS) $(ROOTLINKS) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libw/sparc/Makefile b/usr/src/lib/libw/sparc/Makefile index 0351e399ad..c318e6089b 100644 --- a/usr/src/lib/libw/sparc/Makefile +++ b/usr/src/lib/libw/sparc/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,13 +19,13 @@ # CDDL HEADER END # # -# Copyright 2003 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com -.KEEP_STATE: +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) -install: all $(ROOTLIBS) $(ROOTLINKS) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libw/sparcv9/Makefile b/usr/src/lib/libw/sparcv9/Makefile index 0c09de3ef5..70f0fc2457 100644 --- a/usr/src/lib/libw/sparcv9/Makefile +++ b/usr/src/lib/libw/sparcv9/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,16 +19,14 @@ # CDDL HEADER END # # -# Copyright 2003 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.lib.64 -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -.KEEP_STATE: - -install: all $(ROOTLIBS64) $(ROOTLINKS64) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libxnet/Makefile b/usr/src/lib/libxnet/Makefile index f663bdff96..6cb7a4fa8a 100644 --- a/usr/src/lib/libxnet/Makefile +++ b/usr/src/lib/libxnet/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,31 +19,26 @@ # CDDL HEADER END # # -# Copyright 2003 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" -# -# lib/libxnet/Makefile include ../Makefile.lib -SUBDIRS= $(MACH) $(BUILD64) $(MACH64) +SUBDIRS = $(MACH) $(BUILD64) $(MACH64) all := TARGET= all clean := TARGET= clean clobber := TARGET= clobber -delete := TARGET= delete install := TARGET= install -lint := TARGET= lint -_msg := TARGET= _msg -package := TARGET= package .KEEP_STATE: -all clean clobber delete install lint package: $(SUBDIRS) +all clean clobber install: $(SUBDIRS) + +lint: -$(MACH) $(MACH64): FRC - @cd $@; pwd; $(MAKE) $(TARGET) +$(SUBDIRS): FRC + @cd $@; pwd; $(MAKE) $(TARGET) FRC: diff --git a/usr/src/lib/libxnet/Makefile.com b/usr/src/lib/libxnet/Makefile.com index cd7754cf37..70dccf0033 100644 --- a/usr/src/lib/libxnet/Makefile.com +++ b/usr/src/lib/libxnet/Makefile.com @@ -19,41 +19,15 @@ # 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" -# - -LIBRARY= libxnet.a -VERS= .1 -OBJECTS= data.o - -include ../../Makefile.lib - -# install this library in the root filesystem -include ../../Makefile.rootfs -MAPFILES += $(MAPFILE.FLT) +LIBRARY = libxnet.a +VERS = .1 -SRCDIR= ../common -LIBS= $(DYNLIB) $(LINTLIB) +include $(SRC)/lib/Makefile.rootfs -$(LINTLIB):= SRCS = $(SRCDIR)/$(LINTSRC) - -CPPFLAGS += -D__EXTENSIONS__ -CFLAGS += $(CCVERBOSE) +LIBS += $(LINTLIB) DYNFLAGS += $(ZLOADFLTR) - -# Redefine shared object build rule to use $(LD) directly (this avoids .init -# and .fini sections being added). - -BUILD.SO= $(LD) -o $@ -G $(DYNFLAGS) $(PICS) - -.KEEP_STATE: - -all: $(LIBS) - -lint: lintcheck - -include ../../Makefile.targ +CPPFLAGS += -D__EXTENSIONS__ diff --git a/usr/src/lib/libxnet/amd64/Makefile b/usr/src/lib/libxnet/amd64/Makefile index b6175cc0ce..70f0fc2457 100644 --- a/usr/src/lib/libxnet/amd64/Makefile +++ b/usr/src/lib/libxnet/amd64/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,16 +19,14 @@ # CDDL HEADER END # # -# Copyright 2003 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.lib.64 -.KEEP_STATE: +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) $(PICS) - -install: all $(ROOTLIBS64) $(ROOTLINKS64) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libxnet/common/data.c b/usr/src/lib/libxnet/common/data.c deleted file mode 100644 index eccdbd746a..0000000000 --- a/usr/src/lib/libxnet/common/data.c +++ /dev/null @@ -1,39 +0,0 @@ -/* - * CDDL HEADER START - * - * The contents of this file are subject to the terms of the - * Common Development and Distribution License, Version 1.0 only - * (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) 1996, by Sun Microsystems, Inc. - * All rights reserved. - */ -#pragma ident "%Z%%M% %I% %E% SMI" - -/* - * Define any exported data items. These have to be described within an object - * rather than a mapfile so that they are assigned to a valid section (and thus - * do not result in absolute symbols). - * - * Both of these symbols originate from libnsl. h_error is an uninitialized - * data item where as t_errno is initialized - the value provided here is - * irrelevant but necessary to generate an appropriate copy relocation should - * an application reference this symbol. - */ -int h_errno; -int t_errno = 0; diff --git a/usr/src/lib/libxnet/common/mapfile-vers b/usr/src/lib/libxnet/common/mapfile-vers index 107f590b75..bae43c0320 100644 --- a/usr/src/lib/libxnet/common/mapfile-vers +++ b/usr/src/lib/libxnet/common/mapfile-vers @@ -130,7 +130,7 @@ SUNW_1.1 { getservent = FUNCTION FILTER libsocket.so.1; getsockname = FUNCTION FILTER libsocket.so.1; getsockopt = FUNCTION FILTER libsocket.so.1; - h_errno = NODIRECT FILTER libnsl.so.1; + h_errno = DATA S0x4 NODIRECT FILTER libnsl.so.1; htonl = FUNCTION FILTER libc.so.1; htons = FUNCTION FILTER libc.so.1; inet_addr = FUNCTION FILTER libnsl.so.1; @@ -156,7 +156,7 @@ SUNW_1.1 { shutdown = FUNCTION FILTER libsocket.so.1; socket = FUNCTION FILTER libsocket.so.1; socketpair = FUNCTION FILTER libsocket.so.1; - t_errno = FILTER libnsl.so.1; + t_errno = DATA S0x4 FILTER libnsl.so.1; local: *; }; diff --git a/usr/src/lib/libxnet/i386/Makefile b/usr/src/lib/libxnet/i386/Makefile index 06c850e43c..4e4e8c02a9 100644 --- a/usr/src/lib/libxnet/i386/Makefile +++ b/usr/src/lib/libxnet/i386/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,13 +19,13 @@ # CDDL HEADER END # # -# Copyright 2003 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com -.KEEP_STATE: +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libxnet/sparc/Makefile b/usr/src/lib/libxnet/sparc/Makefile index 06c850e43c..4e4e8c02a9 100644 --- a/usr/src/lib/libxnet/sparc/Makefile +++ b/usr/src/lib/libxnet/sparc/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,13 +19,13 @@ # CDDL HEADER END # # -# Copyright 2003 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com -.KEEP_STATE: +install: all $(ROOTLIBDIR) .WAIT $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) -install: all $(ROOTLIBS) $(ROOTLINKS) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ diff --git a/usr/src/lib/libxnet/sparcv9/Makefile b/usr/src/lib/libxnet/sparcv9/Makefile index b6175cc0ce..70f0fc2457 100644 --- a/usr/src/lib/libxnet/sparcv9/Makefile +++ b/usr/src/lib/libxnet/sparcv9/Makefile @@ -2,9 +2,8 @@ # CDDL HEADER START # # The contents of this file are subject to the terms of the -# Common Development and Distribution License, Version 1.0 only -# (the "License"). You may not use this file except in compliance -# with the License. +# 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. @@ -20,16 +19,14 @@ # CDDL HEADER END # # -# Copyright 2003 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 $(SRC)/lib/Makefile.filter.com include ../Makefile.com -include ../../Makefile.lib.64 +include $(SRC)/lib/Makefile.lib.64 -.KEEP_STATE: +install: all $(ROOTLIBDIR64) .WAIT $(ROOTLIBS64) $(ROOTLINKS64) -BUILD.SO= $(LD) -o $@ -G -64 $(DYNFLAGS) $(PICS) - -install: all $(ROOTLIBS64) $(ROOTLINKS64) $(ROOTLINT) +include $(SRC)/lib/Makefile.filter.targ |