1# 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 2007 Sun Microsystems, Inc. All rights reserved. 23# Use is subject to license terms. 24# 25# Copyright 2015 RackTop Systems. 26# 27 28PROG= rpc.rexd on 29# where under 30#RPCGEN= rpcgen 31REXDPROG= rpc.rexd 32ONPROG = on 33 34MANIFEST= rex.xml 35 36include ../Makefile.cmd 37 38CERRWARN += -_gcc=-Wno-implicit-function-declaration 39CERRWARN += -_gcc=-Wno-parentheses 40CERRWARN += -_gcc=-Wno-unused-variable 41CERRWARN += -_gcc=-Wno-address 42CERRWARN += -_gcc=-Wno-unused-function 43CERRWARN += -_gcc=-Wno-extra 44 45ROOTMANIFESTDIR= $(ROOTSVCNETWORKRPC) 46 47SRCS= $(PROG:%=%.c) 48 49#OBJS= errprintf.o mount_nfs.o rex_xdr.o unix_login.o mntent.o 50TYPEOBJS= nfs_subr.o 51OBJS= errprintf.o mount_nfs.o rex.o unix_login.o mntent.o $(TYPEOBJS) 52REXDOBJS= rpc.rexd.o errprintf.o mount_nfs.o rex.o unix_login.o mntent.o 53ONOBJS= on.o sharetab.o where.o rex.o mntent.o 54#WHEREOBJS= sharetab.o where.o where_main.o mntent.o 55CLEANOBJS= exportent.o sharetab.o on.o rpc.rexd.o where.o 56#under.o where.o where_main.o 57#UNDEROBJS= errprintf.o sharetab.o mount_nfs.o 58 59ROOTREXD= $(ROOTUSRSBIN) 60ROOTON= $(ROOTBIN) 61ROOTREXDPROG= $(REXDPROG:%=$(ROOTREXD)/%) 62ROOTONPROG= $(ONPROG:%=$(ROOTON)/%) 63 64CPPFLAGS = -I. $(CPPFLAGS.master) 65 66LDLIBS += -lsocket -lnsl 67rpc.rexd := LDLIBS += -lrpcsvc -lbsm -lpam 68 69TYPESRCS= ../nfs/lib/nfs_subr.c 70 71# install rule 72# don't re-install directories created by Targetdirs 73#$(ROOTREXD)/%: % 74# $(INS.file) 75#$(ROOTON)/%: % 76# $(INS.file) 77 78.KEEP_STATE: 79 80all: $(PROG) 81 82rpc.rexd: $$@.o $(OBJS) 83 $(LINK.c) -o $@ $@.o $(OBJS) $(LDLIBS) 84 $(POST_PROCESS) 85 86on: $(ONOBJS) 87 $(LINK.c) -o $@ $(ONOBJS) $(LDLIBS) 88 $(POST_PROCESS) 89 90#under: $$@.o $(UNDEROBJS) 91# $(LINK.c) -o $@ $@.o $(UNDEROBJS) $(LDLIBS) 92# 93#where: $(WHEREOBJS) 94# $(LINK.c) -o $@ $(WHEREOBJS) $(LDLIBS) 95# 96install: all $(ROOTREXDPROG) $(ROOTONPROG) $(ROOTMANIFEST) 97 98$(ROOTREXD): rpc.rexd 99 $(INS.dir) 100$(ROOTON): on 101 $(INS.dir) 102 103check: $(CHKMANIFEST) 104 105clean: 106 $(RM) $(OBJS) $(CLEANOBJS) $(PROG) 107 108lint: lint_SRCS 109 110include ../Makefile.targ 111 112# derived source files and explicit dependencies 113 114#rex_xdr.o \ 115#rex_svc.o \ 116#rex_clnt.o: rex.h rex.c 117# $(LINK.c) -c -o $@ rex.c $(LDLIBS) 118 119on.o: rex.h 120 121rpc.rexd.o: rex.h 122 123unix_login.o: rex.h 124 125rex.o: rex.h 126 127nfs_subr.o: ../fs.d/nfs/lib/nfs_subr.c 128 $(COMPILE.c) ../fs.d/nfs/lib/nfs_subr.c 129