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

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/hal/hald/Makefile
          +++ new/usr/src/cmd/hal/hald/Makefile
↓ 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 2017 RackTop Systems.
       26 +#
  25   27  
  26   28  SUBDIRS =       solaris
  27   29  
  28   30  PROG =          hald
  29   31  OBJS =          hald_marshal.o device.o device_info.o device_store.o hald.o \
  30   32                  hald_dbus.o hald_runner.o ids.o logger.o property.o util.o \
  31   33                  util_helper.o util_pm.o
  32   34  OBJS_SOL =      devinfo.o devinfo_ieee1394.o devinfo_misc.o devinfo_pci.o devinfo_storage.o \
  33   35                  devinfo_usb.o hotplug.o osspec.o sysevent.o devinfo_acpi.o \
  34   36                  devinfo_cpu.o
↓ open down ↓ 3 lines elided ↑ open up ↑
  38   40  include ../../Makefile.cmd
  39   41  include ../Makefile.hal
  40   42  
  41   43  ROOTCMDDIR =    $(ROOTLIB_HAL)
  42   44  
  43   45  LDLIBS +=       -lc -lm -ldbus-1 -ldbus-glib-1 -lglib-2.0 -lgobject-2.0 \
  44   46                  -ldevinfo -lsysevent -lnvpair -lkstat -lcfgadm
  45   47  
  46   48  all install $(PROG) :=  LDLIBS += -lexpat
  47   49  
       50 +# Allow HAL to take some of its dependencies from outside the proto area.
       51 +$(ADJUNCT_PROTO_NOT_SET)LDFLAGS += $(ZASSERTDEFLIB)=libdbus-1.so
       52 +$(ADJUNCT_PROTO_NOT_SET)LDFLAGS += $(ZASSERTDEFLIB)=libdbus-glib-1.so
       53 +$(ADJUNCT_PROTO_NOT_SET)LDFLAGS += $(ZASSERTDEFLIB)=libglib-2.0.so
       54 +$(ADJUNCT_PROTO_NOT_SET)LDFLAGS += $(ZASSERTDEFLIB)=libgobject-2.0.so
       55 +$(ADJUNCT_PROTO_NOT_SET)LDFLAGS += $(ZASSERTDEFLIB)=libexpat.so
       56 +
  48   57  CPPFLAGS +=     $(HAL_DBUS_CPPFLAGS) $(HAL_GLIB_CPPFLAGS) $(HAL_CONFIG_CPPFLAGS)
  49   58  C99MODE =       $(C99_ENABLE)
  50   59  
  51   60  CLOBBERFILES += hald_marshal.c hald_marshal.h
  52   61  
  53   62  all :=          TARGET= all
  54   63  install :=      TARGET= install
  55   64  clean :=        TARGET= clean
  56   65  clobber :=      TARGET= clobber
  57   66  $(PROG) :=      TARGET= all
↓ open down ↓ 32 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX