Print this page
10079 smatch Makefile changes for usr/src/lib


   5 # Common Development and Distribution License (the "License").
   6 # You may not use this file except in compliance with the License.
   7 #
   8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
   9 # or http://www.opensolaris.org/os/licensing.
  10 # See the License for the specific language governing permissions
  11 # and limitations under the License.
  12 #
  13 # When distributing Covered Code, include this CDDL HEADER in each
  14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15 # If applicable, add the following below this CDDL HEADER, with the
  16 # fields enclosed by brackets "[]" replaced with your own identifying
  17 # information: Portions Copyright [yyyy] [name of copyright owner]
  18 #
  19 # CDDL HEADER END
  20 #
  21 #
  22 # Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
  23 # Use is subject to license terms.
  24 #

  25 
  26 #
  27 # The build process for libsaveargs is sightly different from that used by other
  28 # libraries, because libsaveargs must be built in two flavors - as a standalone
  29 # for use by kmdb and as a normal library.  We use $(CURTYPE) to indicate the
  30 # current flavor being built.
  31 #
  32 
  33 LIBRARY=        libsaveargs.a
  34 STANDLIBRARY=   libstandsaveargs.so
  35 VERS=           .1
  36 
  37 # By default, we build the shared library.  Construction of the standalone
  38 # is specifically requested by architecture-specific Makefiles.
  39 TYPES=          library
  40 CURTYPE=        library
  41 
  42 COMDIR=         $(SRC)/lib/libsaveargs/common
  43 
  44 OBJECTS_common_amd64    = saveargs.o


  77 $(LINTLIB) := SRCS = $(COMDIR)/$(LINTSRC)
  78 
  79 # We want the thread-specific errno in the library, but we don't want it in
  80 # the standalone.  $(DTS_ERRNO) is designed to add -D_TS_ERRNO to $(CPPFLAGS),
  81 # in order to enable this feature.  Conveniently, -D_REENTRANT does the same
  82 # thing.  As such, we null out $(DTS_ERRNO) to ensure that the standalone
  83 # doesn't get it.
  84 DTS_ERRNO=
  85 
  86 CPPFLAGS_standalone = -DDIS_STANDALONE
  87 CPPFLAGS_library = -D_REENTRANT
  88 CPPFLAGS +=     -I$(COMDIR) $(CPPFLAGS_$(CURTYPE))
  89 
  90 CFLAGS_standalone = $(STAND_FLAGS_32)
  91 CFLAGS_common =
  92 CFLAGS += $(CFLAGS_$(CURTYPE)) $(CFLAGS_common)
  93 
  94 CFLAGS64_standalone = $(STAND_FLAGS_64)
  95 CFLAGS64 += $(CCVERBOSE) $(CFLAGS64_$(CURTYPE)) $(CFLAGS64_common)
  96 



  97 DYNFLAGS +=     $(ZINTERPOSE)
  98 
  99 .KEEP_STATE:


   5 # Common Development and Distribution License (the "License").
   6 # You may not use this file except in compliance with the License.
   7 #
   8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
   9 # or http://www.opensolaris.org/os/licensing.
  10 # See the License for the specific language governing permissions
  11 # and limitations under the License.
  12 #
  13 # When distributing Covered Code, include this CDDL HEADER in each
  14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15 # If applicable, add the following below this CDDL HEADER, with the
  16 # fields enclosed by brackets "[]" replaced with your own identifying
  17 # information: Portions Copyright [yyyy] [name of copyright owner]
  18 #
  19 # CDDL HEADER END
  20 #
  21 #
  22 # Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
  23 # Use is subject to license terms.
  24 #
  25 # Copyright (c) 2018, Joyent, Inc.
  26 
  27 #
  28 # The build process for libsaveargs is sightly different from that used by other
  29 # libraries, because libsaveargs must be built in two flavors - as a standalone
  30 # for use by kmdb and as a normal library.  We use $(CURTYPE) to indicate the
  31 # current flavor being built.
  32 #
  33 
  34 LIBRARY=        libsaveargs.a
  35 STANDLIBRARY=   libstandsaveargs.so
  36 VERS=           .1
  37 
  38 # By default, we build the shared library.  Construction of the standalone
  39 # is specifically requested by architecture-specific Makefiles.
  40 TYPES=          library
  41 CURTYPE=        library
  42 
  43 COMDIR=         $(SRC)/lib/libsaveargs/common
  44 
  45 OBJECTS_common_amd64    = saveargs.o


  78 $(LINTLIB) := SRCS = $(COMDIR)/$(LINTSRC)
  79 
  80 # We want the thread-specific errno in the library, but we don't want it in
  81 # the standalone.  $(DTS_ERRNO) is designed to add -D_TS_ERRNO to $(CPPFLAGS),
  82 # in order to enable this feature.  Conveniently, -D_REENTRANT does the same
  83 # thing.  As such, we null out $(DTS_ERRNO) to ensure that the standalone
  84 # doesn't get it.
  85 DTS_ERRNO=
  86 
  87 CPPFLAGS_standalone = -DDIS_STANDALONE
  88 CPPFLAGS_library = -D_REENTRANT
  89 CPPFLAGS +=     -I$(COMDIR) $(CPPFLAGS_$(CURTYPE))
  90 
  91 CFLAGS_standalone = $(STAND_FLAGS_32)
  92 CFLAGS_common =
  93 CFLAGS += $(CFLAGS_$(CURTYPE)) $(CFLAGS_common)
  94 
  95 CFLAGS64_standalone = $(STAND_FLAGS_64)
  96 CFLAGS64 += $(CCVERBOSE) $(CFLAGS64_$(CURTYPE)) $(CFLAGS64_common)
  97 
  98 # not linted
  99 SMATCH=off
 100 
 101 DYNFLAGS +=     $(ZINTERPOSE)
 102 
 103 .KEEP_STATE: