Print this page
native tools must reliably use a native adjunct, even if that's inconvenient
While it is perhaps convenient for native tools to use updated versions
of certain things like libxml it is imperative that those versions are
_also_ build for the build machine.  Thus they need to be in the native
adjunct (even if that native adjunct is thus not /).
Fix the native adjunct to be rooted similarly to the adjunct proto (that
is, at /), and fix SMF to use it correctly


  62 LDLIBS  += -lsecdb $(MYLDLIBS)
  63 LINTFLAGS += -errtags -erroff=E_BAD_FORMAT_ARG_TYPE2 -erroff=E_NAME_DEF_NOT_USED2
  64 
  65 CLOBBERFILES += $(MYPROG:%=%-native)
  66 
  67 LIBUUTIL        = $(SRC)/lib/libuutil
  68 LIBSCF          = $(SRC)/lib/libscf
  69 
  70 SCRIPTFILE      = restore_repository
  71 ROOTSCRIPTFILE  = $(ROOTCMDDIR)/$(SCRIPTFILE)
  72 
  73 #
  74 # Native variant (used in ../seed)
  75 #
  76 $(NATIVE_BUILD)CC =     $(NATIVECC)
  77 $(NATIVE_BUILD)LD =     $(NATIVELD)
  78 $(NATIVE_BUILD)CFLAGS = $(NATIVE_CFLAGS)
  79 $(NATIVE_BUILD)CPPFLAGS = $(MYCPPFLAGS) -I$(LIBUUTIL)/common -I$(LIBSCF)/inc
  80 $(NATIVE_BUILD)CPPFLAGS += -DNATIVE_BUILD
  81 $(NATIVE_BUILD)LDFLAGS =
  82 $(NATIVE_BUILD)LDLIBS = -L$(ADJUNCT_PROTO)/usr/lib -R$(ADJUNCT_PROTO)/usr/lib \

  83                         -L$(LIBUUTIL)/native -R $(LIBUUTIL)/native $(MYLDLIBS)
  84 
  85 DIRMODE = 0755
  86 FILEMODE = 0555
  87 
  88 OBJSQLITE =
  89 LIBSQLITE = -lsqlite-sys
  90 $(NATIVE_BUILD)OBJSQLITE = $(ROOT)/lib/libsqlite-native.o
  91 $(NATIVE_BUILD)LIBSQLITE =
  92 
  93 OBJS += $(OBJSQLITE)
  94 LDLIBS += $(LIBSQLITE)
  95 
  96 install := TARGET = install
  97 clobber := TARGET = clobber
  98 
  99 .KEEP_STATE:
 100 .PARALLEL: $(MYOBJS) $(MYOBJS:%.o=%-native.o)
 101 
 102 all: $(PROG)




  62 LDLIBS  += -lsecdb $(MYLDLIBS)
  63 LINTFLAGS += -errtags -erroff=E_BAD_FORMAT_ARG_TYPE2 -erroff=E_NAME_DEF_NOT_USED2
  64 
  65 CLOBBERFILES += $(MYPROG:%=%-native)
  66 
  67 LIBUUTIL        = $(SRC)/lib/libuutil
  68 LIBSCF          = $(SRC)/lib/libscf
  69 
  70 SCRIPTFILE      = restore_repository
  71 ROOTSCRIPTFILE  = $(ROOTCMDDIR)/$(SCRIPTFILE)
  72 
  73 #
  74 # Native variant (used in ../seed)
  75 #
  76 $(NATIVE_BUILD)CC =     $(NATIVECC)
  77 $(NATIVE_BUILD)LD =     $(NATIVELD)
  78 $(NATIVE_BUILD)CFLAGS = $(NATIVE_CFLAGS)
  79 $(NATIVE_BUILD)CPPFLAGS = $(MYCPPFLAGS) -I$(LIBUUTIL)/common -I$(LIBSCF)/inc
  80 $(NATIVE_BUILD)CPPFLAGS += -DNATIVE_BUILD
  81 $(NATIVE_BUILD)LDFLAGS =
  82 $(NATIVE_BUILD)LDLIBS = -L$(NATIVE_ADJUNCT)/usr/lib \
  83                         -R$(NATIVE_ADJUNCT)/usr/lib \
  84                         -L$(LIBUUTIL)/native -R $(LIBUUTIL)/native $(MYLDLIBS)
  85 
  86 DIRMODE = 0755
  87 FILEMODE = 0555
  88 
  89 OBJSQLITE =
  90 LIBSQLITE = -lsqlite-sys
  91 $(NATIVE_BUILD)OBJSQLITE = $(ROOT)/lib/libsqlite-native.o
  92 $(NATIVE_BUILD)LIBSQLITE =
  93 
  94 OBJS += $(OBJSQLITE)
  95 LDLIBS += $(LIBSQLITE)
  96 
  97 install := TARGET = install
  98 clobber := TARGET = clobber
  99 
 100 .KEEP_STATE:
 101 .PARALLEL: $(MYOBJS) $(MYOBJS:%.o=%-native.o)
 102 
 103 all: $(PROG)