17c478bd9Sstevel@tonic-gate# 27c478bd9Sstevel@tonic-gate# CDDL HEADER START 37c478bd9Sstevel@tonic-gate# 47c478bd9Sstevel@tonic-gate# The contents of this file are subject to the terms of the 524da5b34Srie# Common Development and Distribution License (the "License"). 624da5b34Srie# You may not use this file except in compliance with the License. 77c478bd9Sstevel@tonic-gate# 87c478bd9Sstevel@tonic-gate# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 97c478bd9Sstevel@tonic-gate# or http://www.opensolaris.org/os/licensing. 107c478bd9Sstevel@tonic-gate# See the License for the specific language governing permissions 117c478bd9Sstevel@tonic-gate# and limitations under the License. 127c478bd9Sstevel@tonic-gate# 137c478bd9Sstevel@tonic-gate# When distributing Covered Code, include this CDDL HEADER in each 147c478bd9Sstevel@tonic-gate# file and include the License file at usr/src/OPENSOLARIS.LICENSE. 157c478bd9Sstevel@tonic-gate# If applicable, add the following below this CDDL HEADER, with the 167c478bd9Sstevel@tonic-gate# fields enclosed by brackets "[]" replaced with your own identifying 177c478bd9Sstevel@tonic-gate# information: Portions Copyright [yyyy] [name of copyright owner] 187c478bd9Sstevel@tonic-gate# 197c478bd9Sstevel@tonic-gate# CDDL HEADER END 207c478bd9Sstevel@tonic-gate# 2124da5b34Srie 227c478bd9Sstevel@tonic-gate# 2324fe0b3bSjmcp# Copyright 2009 Sun Microsystems, Inc. All rights reserved. 2424da5b34Srie# Use is subject to license terms. 257c478bd9Sstevel@tonic-gate# 265661bb76SJohn Levon# Copyright (c) 2018, Joyent, Inc. 275661bb76SJohn Levon 287c478bd9Sstevel@tonic-gatePROG= listen nlps_server 297c478bd9Sstevel@tonic-gate 307c478bd9Sstevel@tonic-gateDBGOBJ = doprnt.o 317c478bd9Sstevel@tonic-gateDBGSRC = doprnt.c 3224fe0b3bSjmcp 337c478bd9Sstevel@tonic-gateLSOBJS = listen.o lslog.o lsdbf.o lsdata.o nstoa.o nlsaddr.o 3424fe0b3bSjmcp 357c478bd9Sstevel@tonic-gateNLPSOBJS = nlps_serv.o lsdbf.o lssmb.o nstoa.o lslog.o lsdata.o 367c478bd9Sstevel@tonic-gate 377c478bd9Sstevel@tonic-gateOBJS= $(LSOBJS) $(NLPSOBJS) 387c478bd9Sstevel@tonic-gateLSSRC= $(LSOBJS:%.o=%.c) 397c478bd9Sstevel@tonic-gateNLPSSRC= $(NLPSOBJS:%.o=%.c) 407c478bd9Sstevel@tonic-gateSRCS= $(LSSRC) $(NLPSSRC) 417c478bd9Sstevel@tonic-gate 427c478bd9Sstevel@tonic-gateinclude ../Makefile.cmd 437c478bd9Sstevel@tonic-gate 447c478bd9Sstevel@tonic-gateLIBSAFD = $(ROOTLIB)/saf 457c478bd9Sstevel@tonic-gateNETD = $(ROOT)/usr/net 467c478bd9Sstevel@tonic-gateNETNLSD = $(NETD)/nls 477c478bd9Sstevel@tonic-gate 487c478bd9Sstevel@tonic-gate# Don"t re-install /usr/lib/saf/ and /usr/net, Targetdirs installs them 497c478bd9Sstevel@tonic-gate#DIRS= $(LIBSAFD) $(NETD) $(NETNLSD) 507c478bd9Sstevel@tonic-gateDIRS= $(NETNLSD) 51*85f4cb87SRichard LoweROOTSAFPROG= $(PROG:%=$(LIBSAFD)/%) 527c478bd9Sstevel@tonic-gate 5324da5b34Srie# If machine name and /etc/issue file need to be printed 5424da5b34Srie# before the service prompt is printed, then: CPPFLAGS += -DSYS_NAME 557c478bd9Sstevel@tonic-gate# If debug is needed, then: CPPFLAGS += -DDEBUG 567c478bd9Sstevel@tonic-gate 577c478bd9Sstevel@tonic-gateLDLIBS += -lnsl 58*85f4cb87SRichard LoweLDFLAGS += $(MAPFILE.NGB:%=-Wl,-M%) 597c478bd9Sstevel@tonic-gateFILEMODE= 0755 607c478bd9Sstevel@tonic-gate 617014882cSRichard LoweCERRWARN += -_gcc=-Wno-implicit-function-declaration 627014882cSRichard LoweCERRWARN += -_gcc=-Wno-unused-variable 637014882cSRichard LoweCERRWARN += -_gcc=-Wno-empty-body 647014882cSRichard LoweCERRWARN += -_gcc=-Wno-parentheses 65d3b5f563SJohn LevonCERRWARN += $(CNOWARN_UNINIT) 667014882cSRichard Lowe 675661bb76SJohn Levon# not linted 685661bb76SJohn LevonSMATCH=off 695661bb76SJohn Levon 707c478bd9Sstevel@tonic-gate$(LIBSAFD)/% : % 717c478bd9Sstevel@tonic-gate $(INS.file) 727c478bd9Sstevel@tonic-gate 737c478bd9Sstevel@tonic-gate.KEEP_STATE: 747c478bd9Sstevel@tonic-gate 7524da5b34Srieall: $(PROG) 767c478bd9Sstevel@tonic-gate 7724da5b34Srielisten: $(LSOBJS) $(MAPFILE.NGB) 787c478bd9Sstevel@tonic-gate $(LINK.c) $(LSOBJS) -o $@ $(LDLIBS) 797c478bd9Sstevel@tonic-gate $(POST_PROCESS) 807c478bd9Sstevel@tonic-gate 8124da5b34Srienlps_server: $(NLPSOBJS) $(MAPFILE.NGB) 827c478bd9Sstevel@tonic-gate $(LINK.c) $(NLPSOBJS) -o $@ $(LDLIBS) 837c478bd9Sstevel@tonic-gate $(POST_PROCESS) 847c478bd9Sstevel@tonic-gate 857c478bd9Sstevel@tonic-gateinstall: all $(DIRS) $(ROOTSAFPROG) 867c478bd9Sstevel@tonic-gate $(RM) $(ROOT)/usr/net/nls/listen 877c478bd9Sstevel@tonic-gate -$(SYMLINK) ../../lib/saf/listen $(ROOT)/usr/net/nls/listen 887c478bd9Sstevel@tonic-gate $(RM) $(ROOT)/usr/net/nls/nlps_server 897c478bd9Sstevel@tonic-gate -$(SYMLINK) ../../lib/saf/nlps_server $(ROOT)/usr/net/nls/nlps_server 907c478bd9Sstevel@tonic-gate 917c478bd9Sstevel@tonic-gate$(DIRS): 927c478bd9Sstevel@tonic-gate $(INS.dir) 937c478bd9Sstevel@tonic-gate 947c478bd9Sstevel@tonic-gateclean: 957c478bd9Sstevel@tonic-gate $(RM) $(OBJS) 967c478bd9Sstevel@tonic-gate 977c478bd9Sstevel@tonic-gateinclude ../Makefile.targ 98