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

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/svc/svccfg/Makefile
          +++ new/usr/src/cmd/svc/svccfg/Makefile
↓ open down ↓ 13 lines elided ↑ open up ↑
  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  #
  23   23  # Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved.
       24 +# Copyright 2017 RackTop Systems.
  24   25  #
  25   26  
  26   27  MYPROG =        svccfg
  27   28  PROG =          $(MYPROG)
  28   29  
  29   30  SRCS  =         svccfg_main.c \
  30   31                  svccfg_engine.c \
  31   32                  svccfg_internal.c \
  32   33                  svccfg_libscf.c \
  33   34                  svccfg_tmpl.c \
↓ open down ↓ 48 lines elided ↑ open up ↑
  82   83  
  83   84  LFLAGS = -t
  84   85  YFLAGS = -d
  85   86  
  86   87  CLOBBERFILES += svccfg_lex.c svccfg_grammar.c svccfg_grammar.h \
  87   88      $(MYPROG:%=%-native)
  88   89  
  89   90  SVCCFG_EXTRA_LIBS = -lxml2 -lscf -ll -luutil -lumem -lmd5 -lnvpair
  90   91  $(NOT_NATIVE)SVCCFG_EXTRA_LIBS += -ltecla
  91   92  
       93 +# Allow libxml2 to be taken from outside the proto area.
       94 +$(ADJUNCT_PROTO_NOT_SET)LDFLAGS += $(ZASSERTDEFLIB)=libxml2.so
       95 +
  92   96  LIBSCF          = $(SRC)/lib/libscf
  93   97  LIBTECLA        = $(SRC)/lib/libtecla           # just for the header
  94   98  LIBUUTIL        = $(SRC)/lib/libuutil
  95   99  
  96  100  debug := COPTFLAG = -g
  97  101  
  98  102  lint := LINTFLAGS = -mux
  99  103  lint := SVCCFG_EXTRA_LIBS = -lscf -ll -luutil -lumem -lmd5 -lnvpair
 100  104  
 101  105  LDLIBS += $(SVCCFG_EXTRA_LIBS)
↓ open down ↓ 75 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX