Print this page
5840 cmd/ypcmd build failed without usr/lib/libsocket.so on build host


   2 # CDDL HEADER START
   3 #
   4 # The contents of this file are subject to the terms of the
   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 2009 Sun Microsystems, Inc.  All rights reserved.
  23 # Use is subject to license terms.
  24 #
  25 
  26 BINPROG = ypmatch ypwhich ypcat
  27 SBINPROG = makedbm ypalias ypinit yppoll ypset
  28 NETYPPROG = ypbind ypxfr yppush udpublickey mkalias \
  29                 multi multi.awk stdethers stdhosts \
  30                 ypxfr_1perday ypxfr_1perhour ypxfr_2perday \
  31                 ypstart ypstop
  32 NIS2LDAPPROG = ypxfrd ypserv ypxfr
  33 SVCMETHOD = yp
  34 PROG=   $(BINPROG) $(SBINPROG) $(NETYPPROG) $(NIS2LDAPPROG) $(SVCMETHOD)
  35 
  36 MANIFEST = server.xml client.xml xfr.xml
  37 




  38 include ../Makefile.cmd
  39 
  40 ROOTMANIFESTDIR = $(ROOTSVCNETWORKNIS)
  41 
  42 # installed directories
  43 NETSVC = $(ROOTLIB)/netsvc
  44 NETYP = $(NETSVC)/yp
  45 
  46 ROOTVAR_YP = $(ROOT)/var/yp
  47 ROOTBINDING = $(ROOTVAR_YP)/binding
  48 ROOTDIRS =      $(ROOT) $(ROOTUSR) $(ROOTLIB) $(ROOTETC) $(ROOTVAR) \
  49                 $(NETSVC) $(NETYP) $(ROOTVAR_YP) $(ROOTBINDING) \
  50                 $(ROOTUSRSBIN) $(ROOTBIN)
  51 
  52 $(BINPROG) :=   LDLIBS += -lnsl
  53 $(NETYPPROG) := LDLIBS += -lnsl
  54 $(NIS2LDAPPROG) := LDLIBS += -lc -lnsl -lnisdb
  55 ypinit :=       LDLIBS += -lnsl
  56 yppoll :=       LDLIBS += -lnsl
  57 ypset :=        LDLIBS += -lnsl
  58 makedbm :=      MAPFILES = $(MAPFILE.INT) $(MAPFILE.NGB)
  59 makedbm :=      LDFLAGS += $(MAPFILES:%=-M%)
  60 
  61 $(ROOTVAR_YP)/aliases :=        FILEMODE=555
  62 
  63 YPFILES = Makefile aliases nicknames updaters
  64 ETCFILES =  publickey
  65 ROOTYPFILES= $(YPFILES:%=$(ROOTVAR_YP)/%)
  66 ROOTETCFILE= $(ETCFILES:%=$(ROOTETC)/%)
  67 
  68 TXTS=   $(ETCFILES:%=net_files/%) $(YPFILES:%=net_files/%)
  69 SUBDIRS = yppasswd mknetid revnetgroup ypupdated yp2lscripts
  70 
  71 YPBINDOBJ= yp_b_svc.o yp_b_subr.o rpc_bootstrap.o getlist.o
  72 #
  73 # Some sort of obsolete idea of common files which are only now used by a 
  74 # few minor utilities
  75 #
  76 COMMONOBJ= getlist.o yp_getalias.o 
  77 


 226 ypxfrd: $(YPXFRDOBJ) $(SHAREDOBJ)
 227         $(LINK.cc) $(YPXFRDOBJ) $(SHAREDOBJ) \
 228         -o $@ $(LDLIBS) -lc
 229         $(POST_PROCESS)
 230 
 231 ypxfr: $(YPXFROBJ) $(COMMONOBJ) $(YPMASTEROBJ) $(SHAREDOBJ)
 232         $(LINK.cc) -o $@ $(YPXFROBJ) $(YPMASTEROBJ) $(COMMONOBJ) \
 233                 $(SHAREDOBJ) $(LDLIBS)
 234         $(POST_PROCESS)
 235 
 236 ypserv: $(YPSERVOBJ) $(COMMONOBJ) $(SHAREDOBJ)
 237         $(LINK.cc) $(YPSERVOBJ) $(COMMONOBJ) \
 238                 $(SHAREDOBJ) -o $@ $(LDLIBS)
 239         $(POST_PROCESS)
 240 
 241 yppush: $(YPPUSHOBJ) $(COMMONOBJ)
 242         $(LINK.c) $(YPPUSHOBJ) $(COMMONOBJ) -o $@ $(LDLIBS)
 243         $(POST_PROCESS)
 244 
 245 udpublickey: $(UDPUBLICKEYOBJ)
 246         $(LINK.c) $(UDPUBLICKEYOBJ) -o $@
 247         $(POST_PROCESS)
 248 
 249 mkalias: $(MKALIASOBJ)
 250         $(LINK.c) $(MKALIASOBJ) -o $@ -lnsl
 251         $(POST_PROCESS)
 252 
 253 stdethers: $(STDETHERSOBJ)
 254         $(LINK.c) $(STDETHERSOBJ) -o $@ -lsocket
 255         $(POST_PROCESS)
 256 
 257 stdhosts: $(STDHOSTSOBJ)
 258         $(LINK.c) $(STDHOSTSOBJ) -o $@ $(LDLIBS)
 259         $(POST_PROCESS)
 260 
 261 install: all $(PROG) $(ROOTDIRS) $(ROOTETCFILE) $(ROOTYPFILES) $(IBINPROG) \
 262         $(ISBINPROG) $(INETYPPROG) $(INIS2LDAPPROG) $(SUBDIRS) $(ROOTMANIFEST) \
 263         $(ROOTSVCMETHOD)
 264 
 265 $(ROOTDIRS):
 266         $(INS.dir)
 267 
 268 $(SUBDIRS): FRC
 269         @cd $@; pwd; $(MAKE) $(TARGET)
 270 
 271 lint := CPPFLAGS += -I$(SRC)/lib/libnisdb/yptol
 272 
 273 lint:   $(SUBDIRS)
 274         $(LINT.c) ypmatch.c nick.c -lnsl




   2 # CDDL HEADER START
   3 #
   4 # The contents of this file are subject to the terms of the
   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 2015 Gary Mills
  23 # Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  24 # Use is subject to license terms.
  25 #
  26 
  27 BINPROG = ypmatch ypwhich ypcat
  28 SBINPROG = makedbm ypalias ypinit yppoll ypset
  29 NETYPPROG = ypbind ypxfr yppush udpublickey mkalias \
  30                 multi multi.awk stdethers stdhosts \
  31                 ypxfr_1perday ypxfr_1perhour ypxfr_2perday \
  32                 ypstart ypstop
  33 NIS2LDAPPROG = ypxfrd ypserv ypxfr
  34 SVCMETHOD = yp
  35 PROG=   $(BINPROG) $(SBINPROG) $(NETYPPROG) $(NIS2LDAPPROG) $(SVCMETHOD)
  36 
  37 MANIFEST = server.xml client.xml xfr.xml
  38 
  39 # These only need -lnsl
  40 LNSLPROG = ypmatch ypwhich ypcat yppoll ypset \
  41         ypbind ypxfr yppush mkalias stdhosts
  42 
  43 include ../Makefile.cmd
  44 
  45 ROOTMANIFESTDIR = $(ROOTSVCNETWORKNIS)
  46 
  47 # installed directories
  48 NETSVC = $(ROOTLIB)/netsvc
  49 NETYP = $(NETSVC)/yp
  50 
  51 ROOTVAR_YP = $(ROOT)/var/yp
  52 ROOTBINDING = $(ROOTVAR_YP)/binding
  53 ROOTDIRS =      $(ROOT) $(ROOTUSR) $(ROOTLIB) $(ROOTETC) $(ROOTVAR) \
  54                 $(NETSVC) $(NETYP) $(ROOTVAR_YP) $(ROOTBINDING) \
  55                 $(ROOTUSRSBIN) $(ROOTBIN)
  56 
  57 $(LNSLPROG) :=  LDLIBS += -lnsl

  58 $(NIS2LDAPPROG) := LDLIBS += -lc -lnsl -lnisdb
  59 stdethers :=    LDLIBS += -lsocket


  60 makedbm :=      MAPFILES = $(MAPFILE.INT) $(MAPFILE.NGB)
  61 makedbm :=      LDFLAGS += $(MAPFILES:%=-M%)
  62 
  63 $(ROOTVAR_YP)/aliases :=        FILEMODE=555
  64 
  65 YPFILES = Makefile aliases nicknames updaters
  66 ETCFILES =  publickey
  67 ROOTYPFILES= $(YPFILES:%=$(ROOTVAR_YP)/%)
  68 ROOTETCFILE= $(ETCFILES:%=$(ROOTETC)/%)
  69 
  70 TXTS=   $(ETCFILES:%=net_files/%) $(YPFILES:%=net_files/%)
  71 SUBDIRS = yppasswd mknetid revnetgroup ypupdated yp2lscripts
  72 
  73 YPBINDOBJ= yp_b_svc.o yp_b_subr.o rpc_bootstrap.o getlist.o
  74 #
  75 # Some sort of obsolete idea of common files which are only now used by a 
  76 # few minor utilities
  77 #
  78 COMMONOBJ= getlist.o yp_getalias.o 
  79 


 228 ypxfrd: $(YPXFRDOBJ) $(SHAREDOBJ)
 229         $(LINK.cc) $(YPXFRDOBJ) $(SHAREDOBJ) \
 230         -o $@ $(LDLIBS) -lc
 231         $(POST_PROCESS)
 232 
 233 ypxfr: $(YPXFROBJ) $(COMMONOBJ) $(YPMASTEROBJ) $(SHAREDOBJ)
 234         $(LINK.cc) -o $@ $(YPXFROBJ) $(YPMASTEROBJ) $(COMMONOBJ) \
 235                 $(SHAREDOBJ) $(LDLIBS)
 236         $(POST_PROCESS)
 237 
 238 ypserv: $(YPSERVOBJ) $(COMMONOBJ) $(SHAREDOBJ)
 239         $(LINK.cc) $(YPSERVOBJ) $(COMMONOBJ) \
 240                 $(SHAREDOBJ) -o $@ $(LDLIBS)
 241         $(POST_PROCESS)
 242 
 243 yppush: $(YPPUSHOBJ) $(COMMONOBJ)
 244         $(LINK.c) $(YPPUSHOBJ) $(COMMONOBJ) -o $@ $(LDLIBS)
 245         $(POST_PROCESS)
 246 
 247 udpublickey: $(UDPUBLICKEYOBJ)
 248         $(LINK.c) $(UDPUBLICKEYOBJ) -o $@ $(LDLIBS)
 249         $(POST_PROCESS)
 250 
 251 mkalias: $(MKALIASOBJ)
 252         $(LINK.c) $(MKALIASOBJ) -o $@ $(LDLIBS)
 253         $(POST_PROCESS)
 254 
 255 stdethers: $(STDETHERSOBJ)
 256         $(LINK.c) $(STDETHERSOBJ) -o $@ $(LDLIBS)
 257         $(POST_PROCESS)
 258 
 259 stdhosts: $(STDHOSTSOBJ)
 260         $(LINK.c) $(STDHOSTSOBJ) -o $@ $(LDLIBS)
 261         $(POST_PROCESS)
 262 
 263 install: all $(PROG) $(ROOTDIRS) $(ROOTETCFILE) $(ROOTYPFILES) $(IBINPROG) \
 264         $(ISBINPROG) $(INETYPPROG) $(INIS2LDAPPROG) $(SUBDIRS) $(ROOTMANIFEST) \
 265         $(ROOTSVCMETHOD)
 266 
 267 $(ROOTDIRS):
 268         $(INS.dir)
 269 
 270 $(SUBDIRS): FRC
 271         @cd $@; pwd; $(MAKE) $(TARGET)
 272 
 273 lint := CPPFLAGS += -I$(SRC)/lib/libnisdb/yptol
 274 
 275 lint:   $(SUBDIRS)
 276         $(LINT.c) ypmatch.c nick.c -lnsl