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


   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 2008 Sun Microsystems, Inc.  All rights reserved.
  23 # Use is subject to license terms.
  24 #


  25 
  26 SUBDIRS =       solaris
  27 
  28 PROG =          hald
  29 OBJS =          hald_marshal.o device.o device_info.o device_store.o hald.o \
  30                 hald_dbus.o hald_runner.o ids.o logger.o property.o util.o \
  31                 util_helper.o util_pm.o
  32 OBJS_SOL =      devinfo.o devinfo_ieee1394.o devinfo_misc.o devinfo_pci.o devinfo_storage.o \
  33                 devinfo_usb.o hotplug.o osspec.o sysevent.o devinfo_acpi.o \
  34                 devinfo_cpu.o
  35 OBJS_ALL =      $(OBJS) $(OBJS_SOL:%=solaris/%)
  36 SRCS =          $(OBJS:%.o=%.c)
  37 
  38 include ../../Makefile.cmd
  39 include ../Makefile.hal
  40 
  41 ROOTCMDDIR =    $(ROOTLIB_HAL)
  42 
  43 LDLIBS +=       -lc -lm -ldbus-1 -ldbus-glib-1 -lglib-2.0 -lgobject-2.0 \
  44                 -ldevinfo -lsysevent -lnvpair -lkstat -lcfgadm
  45 
  46 all install $(PROG) :=  LDLIBS += -lexpat
  47 







  48 CPPFLAGS +=     $(HAL_DBUS_CPPFLAGS) $(HAL_GLIB_CPPFLAGS) $(HAL_CONFIG_CPPFLAGS)
  49 C99MODE =       $(C99_ENABLE)
  50 
  51 CLOBBERFILES += hald_marshal.c hald_marshal.h
  52 
  53 all :=          TARGET= all
  54 install :=      TARGET= install
  55 clean :=        TARGET= clean
  56 clobber :=      TARGET= clobber
  57 $(PROG) :=      TARGET= all
  58 
  59 .KEEP_STATE:
  60 
  61 all: $(SUBDIRS) .WAIT $(PROG)
  62 
  63 hald_marshal.o: hald_marshal.h hald_marshal.c
  64 
  65 hald_marshal.h: hald_marshal.list
  66         glib-genmarshal --prefix=hald_marshal hald_marshal.list --header >> xgen-gmh \
  67         && (cmp -s xgen-gmh hald_marshal.h || cp xgen-gmh hald_marshal.h) \




   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 2008 Sun Microsystems, Inc.  All rights reserved.
  23 # Use is subject to license terms.
  24 #
  25 # Copyright 2017 RackTop Systems.
  26 #
  27 
  28 SUBDIRS =       solaris
  29 
  30 PROG =          hald
  31 OBJS =          hald_marshal.o device.o device_info.o device_store.o hald.o \
  32                 hald_dbus.o hald_runner.o ids.o logger.o property.o util.o \
  33                 util_helper.o util_pm.o
  34 OBJS_SOL =      devinfo.o devinfo_ieee1394.o devinfo_misc.o devinfo_pci.o devinfo_storage.o \
  35                 devinfo_usb.o hotplug.o osspec.o sysevent.o devinfo_acpi.o \
  36                 devinfo_cpu.o
  37 OBJS_ALL =      $(OBJS) $(OBJS_SOL:%=solaris/%)
  38 SRCS =          $(OBJS:%.o=%.c)
  39 
  40 include ../../Makefile.cmd
  41 include ../Makefile.hal
  42 
  43 ROOTCMDDIR =    $(ROOTLIB_HAL)
  44 
  45 LDLIBS +=       -lc -lm -ldbus-1 -ldbus-glib-1 -lglib-2.0 -lgobject-2.0 \
  46                 -ldevinfo -lsysevent -lnvpair -lkstat -lcfgadm
  47 
  48 all install $(PROG) :=  LDLIBS += -lexpat
  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 
  57 CPPFLAGS +=     $(HAL_DBUS_CPPFLAGS) $(HAL_GLIB_CPPFLAGS) $(HAL_CONFIG_CPPFLAGS)
  58 C99MODE =       $(C99_ENABLE)
  59 
  60 CLOBBERFILES += hald_marshal.c hald_marshal.h
  61 
  62 all :=          TARGET= all
  63 install :=      TARGET= install
  64 clean :=        TARGET= clean
  65 clobber :=      TARGET= clobber
  66 $(PROG) :=      TARGET= all
  67 
  68 .KEEP_STATE:
  69 
  70 all: $(SUBDIRS) .WAIT $(PROG)
  71 
  72 hald_marshal.o: hald_marshal.h hald_marshal.c
  73 
  74 hald_marshal.h: hald_marshal.list
  75         glib-genmarshal --prefix=hald_marshal hald_marshal.list --header >> xgen-gmh \
  76         && (cmp -s xgen-gmh hald_marshal.h || cp xgen-gmh hald_marshal.h) \