Print this page
11506 smatch resync

Split Close
Expand all
Collapse all
          --- old/usr/src/lib/libumem/Makefile.com
          +++ new/usr/src/lib/libumem/Makefile.com
↓ open down ↓ 14 lines elided ↑ open up ↑
  15   15  # If applicable, add the following below this CDDL HEADER, with the
  16   16  # fields enclosed by brackets "[]" replaced with your own identifying
  17   17  # information: Portions Copyright [yyyy] [name of copyright owner]
  18   18  #
  19   19  # CDDL HEADER END
  20   20  #
  21   21  #
  22   22  # Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
  23   23  # Use is subject to license terms.
  24   24  #
  25      -# Copyright (c) 2019, Joyent, Inc.
       25 +# Copyright 2019 Joyent, Inc.
  26   26  #
  27   27  
  28   28  #
  29   29  # The build process for libumem is sightly different from that used by other
  30   30  # libraries, because libumem must be built in two flavors - as a standalone
  31   31  # for use by kmdb and as a normal library.  We use $(CURTYPE) to indicate the
  32   32  # current flavor being built.
  33   33  #
  34   34  
  35   35  LIBRARY = libumem.a
↓ open down ↓ 69 lines elided ↑ open up ↑
 105  105  #
 106  106  # Used to verify that the standalone doesn't have any unexpected external
 107  107  # dependencies.
 108  108  #
 109  109  LINKTEST_OBJ = objs/linktest_stand.o
 110  110  
 111  111  CLOBBERFILES_standalone = $(LINKTEST_OBJ)
 112  112  CLOBBERFILES += $(CLOBBERFILES_$(CURTYPE))
 113  113  
 114  114  LIBS_standalone = $(STANDLIBRARY)
 115      -LIBS_library = $(DYNLIB) $(LINTLIB)
      115 +LIBS_library = $(DYNLIB)
 116  116  LIBS =  $(LIBS_$(CURTYPE))
 117  117  
 118  118  MAPFILE_SUPPLEMENTAL_standalone = ../common/stand_mapfile
 119  119  MAPFILE_SUPPLEMENTAL = $(MAPFILE_SUPPLEMENTAL_$(CURTYPE))
 120  120  
 121  121  LDLIBS +=       -lc
 122  122  
 123  123  LDFLAGS_standalone = $(ZNOVERSION) $(BREDUCE) -M../common/mapfile-vers \
 124  124          -M$(MAPFILE_SUPPLEMENTAL) -dy -r
 125  125  LDFLAGS = $(LDFLAGS_$(CURTYPE))
 126  126  
 127  127  ASFLAGS_standalone = -DUMEM_STANDALONE
 128  128  ASFLAGS_library =
 129  129  ASFLAGS += -P $(ASFLAGS_$(CURTYPE)) -D_ASM
 130  130  
 131      -$(LINTLIB) := SRCS = ../common/$(LINTSRC)
 132      -
 133  131  # We want the thread-specific errno in the library, but we don't want it in
 134  132  # the standalone.  $(DTS_ERRNO) is designed to add -D_TS_ERRNO to $(CPPFLAGS),
 135  133  # in order to enable this feature.  Conveniently, -D_REENTRANT does the same
 136  134  # thing.  As such, we null out $(DTS_ERRNO) to ensure that the standalone
 137  135  # doesn't get it.
 138  136  DTS_ERRNO=
 139  137  
 140  138  # We need to rename some standard functions so we can easily implement them
 141  139  # in consumers.
 142  140  STAND_RENAMED_FUNCS= \
↓ open down ↓ 7 lines elided ↑ open up ↑
 150  148  CPPFLAGS_library = -D_REENTRANT
 151  149  CPPFLAGS +=     -I../common -I../../common/inc $(CPPFLAGS_$(CURTYPE))
 152  150  
 153  151  CFLAGS_standalone = $(STAND_FLAGS_32)
 154  152  CFLAGS_common =
 155  153  CFLAGS += $(CFLAGS_$(CURTYPE)) $(CFLAGS_common)
 156  154  
 157  155  CFLAGS64_standalone = $(STAND_FLAGS_64)
 158  156  CFLAGS64 += $(CCVERBOSE) $(CFLAGS64_$(CURTYPE)) $(CFLAGS64_common)
 159  157  
 160      -INSTALL_DEPS_library =          $(ROOTLINKS) $(ROOTLINT) $(ROOTLIBS)
      158 +# false positive for umem_alloc_sizes_add()
      159 +pics/umem.o := SMOFF += index_overflow
      160 +objs/umem.o := SMOFF += index_overflow
 161  161  
 162      -#
 163      -# turn off ptr-cast warnings, since we do them all the time
 164      -#
 165      -LINTFLAGS +=    -erroff=E_BAD_PTR_CAST_ALIGN
 166      -LINTFLAGS64 +=  -erroff=E_BAD_PTR_CAST_ALIGN
      162 +INSTALL_DEPS_library =          $(ROOTLINKS) $(ROOTLIBS)
 167  163  
 168  164  DYNFLAGS +=     $(ZINTERPOSE)
 169  165  
 170  166  .KEEP_STATE:
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX