Print this page
8411 Build should warn when linking against libraries outside proto area

Split Close
Expand all
Collapse all
          --- old/usr/src/lib/fm/topo/libtopo/Makefile.com
          +++ new/usr/src/lib/fm/topo/libtopo/Makefile.com
↓ open down ↓ 12 lines elided ↑ open up ↑
  13   13  # When distributing Covered Code, include this CDDL HEADER in each
  14   14  # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  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 (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
       23 +# Copyright 2017 RackTop Systems.
  23   24  #
  24   25  
  25   26  LIBRARY = libtopo.a
  26   27  VERS = .1
  27   28  
  28   29  BUILTINSRCS = \
  29   30          cpu.c \
  30   31          dev.c \
  31   32          fmd.c \
  32   33          hc.c \
↓ open down ↓ 49 lines elided ↑ open up ↑
  82   83  CERRWARN += -_gcc=-Wno-switch
  83   84  CERRWARN += -_gcc=-Wno-parentheses
  84   85  
  85   86  LINTFLAGS = -msux
  86   87  LINTFLAGS64 = -msux -m64
  87   88  
  88   89  $(DYNLIB)  := LDLIBS += \
  89   90          -lnvpair -lelf -lumem -lxml2 -lkstat -luuid -ldevinfo \
  90   91          -lsmbios -lc -ldevid -lipmi -lscf
  91   92  
       93 +# Allow libxml2 to be taken from the proto area.
       94 +$(ADJUNCT_PROTO_NOT_SET)DYNFLAGS += $(ZASSERTDEFLIB)=libxml2.so
       95 +
  92   96  $(LINTLIB) := SRCS = $(SRCDIR)/$(LINTSRC)
  93   97  $(LINTLIB) := LINTFLAGS = -nsvx
  94   98  $(LINTLIB) := LINTFLAGS64 = -nsvx -m64
  95   99  $(LINTLIB) := LDLIBS += -lnvpair -lumem -lc
  96  100  
  97  101  .KEEP_STATE:
  98  102  
  99  103  all: $(LIBS)
 100  104  
 101  105  lint: $(LINTLIB) lintcheck
↓ open down ↓ 22 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX