1355b4669Sjacobs# 2355b4669Sjacobs# CDDL HEADER START 3355b4669Sjacobs# 4355b4669Sjacobs# The contents of this file are subject to the terms of the 5355b4669Sjacobs# Common Development and Distribution License (the "License"). 6355b4669Sjacobs# You may not use this file except in compliance with the License. 7355b4669Sjacobs# 8355b4669Sjacobs# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9355b4669Sjacobs# or http://www.opensolaris.org/os/licensing. 10355b4669Sjacobs# See the License for the specific language governing permissions 11355b4669Sjacobs# and limitations under the License. 12355b4669Sjacobs# 13355b4669Sjacobs# When distributing Covered Code, include this CDDL HEADER in each 14355b4669Sjacobs# file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15355b4669Sjacobs# If applicable, add the following below this CDDL HEADER, with the 16355b4669Sjacobs# fields enclosed by brackets "[]" replaced with your own identifying 17355b4669Sjacobs# information: Portions Copyright [yyyy] [name of copyright owner] 18355b4669Sjacobs# 19355b4669Sjacobs# CDDL HEADER END 20355b4669Sjacobs# 21355b4669Sjacobs# 22355b4669Sjacobs# Copyright 2006 Sun Microsystems, Inc. All rights reserved. 23355b4669Sjacobs# Use is subject to license terms. 24355b4669Sjacobs# 25355b4669Sjacobs# ident "%Z%%M% %I% %E% SMI" 26355b4669Sjacobs# 27355b4669Sjacobs 28*0a44ef6dSjacobsinclude ../Makefile.sp 29*0a44ef6dSjacobs 30355b4669SjacobsUCBPROGS = lpr lpq lprm lpc 31355b4669SjacobsBINPROGS = lp lpstat cancel enable disable $(UCBPROGS) 32355b4669Sjacobs 33355b4669SjacobsSBINPROGS = accept reject lpmove 34*0a44ef6dSjacobsLIBPRINTPROGS = in.lpd 35355b4669Sjacobs 36355b4669Sjacobs 37*0a44ef6dSjacobsOBJS = $(BINPROGS:=.o) $(SBINPROGS:=.o) $(LIBPRINTPROGS:=.o) common.o 38355b4669Sjacobs 39355b4669SjacobsROOTBINPROGS = $(BINPROGS:%=$(ROOTBIN)/%) 40355b4669SjacobsROOTUSRSBINPROGS = $(SBINPROGS:%=$(ROOTUSRSBIN)/%) 41*0a44ef6dSjacobsROOTLIBPRINTPROGS = $(LIBPRINTPROGS:%=$(ROOTLIBPRINT)/%) 42355b4669Sjacobs 43355b4669Sjacobs 44355b4669SjacobsFILEMODE = 0555 45355b4669SjacobsOWNER = root 46355b4669Sjacobs 47355b4669Sjacobsinclude ../../Makefile.cmd 48355b4669Sjacobs 49*0a44ef6dSjacobsMANIFEST= rfc1179.xml 50*0a44ef6dSjacobsROOTMANIFESTDIR= $(ROOTSVCAPPLICATIONPRINT) 51*0a44ef6dSjacobs$(ROOTMANIFEST) := FILEMODE= 444 52*0a44ef6dSjacobs 53355b4669SjacobsCFLAGS += $(CCVERBOSE) 54355b4669SjacobsCPPFLAGS += -I. 55355b4669SjacobsCPPFLAGS += -I../../../lib/print/libpapi-common/common 56*0a44ef6dSjacobsCPPFLAGS += -I$(ROOT)/usr/include 57355b4669SjacobsLDLIBS += -lpapi -lc 58*0a44ef6dSjacobsin.lpd:= CFLAGS += -DSOLARIS_PRIVATE_POST_0_9 59*0a44ef6dSjacobsin.lpd:= LDLIBS += -lnsl -lsocket 60355b4669Sjacobs 61355b4669Sjacobs# each program needs common.o as well 62*0a44ef6dSjacobs$(BINPROGS) $(SBINPROGS) $(LIBPRINTPROGS): $(BINPROGS:%=%.c) $(SBINPROGS:%=%.c) $(LIBPRINTPROGS:%=%.c) common.o 63355b4669Sjacobs $(LINK.c) -o $@ $@.c common.o $(LDLIBS) 64355b4669Sjacobs $(POST_PROCESS) 65355b4669Sjacobs 66355b4669Sjacobs# ucb links (lptest is handled in usr/src/cmd/lp/cmd/Makefile) 67355b4669SjacobsROOTUSRUCB = $(ROOT)/usr/ucb 68355b4669SjacobsROOTUCBSYMLINKS = $(UCBPROGS:%=$(ROOTUSRUCB)/%) 69355b4669Sjacobs$(ROOTUSRUCB)/%: $(ROOTUSRUCB) % 70355b4669Sjacobs 71355b4669Sjacobs$(ROOTUCBSYMLINKS): 72355b4669Sjacobs $(RM) $@; $(SYMLINK) ../bin/$(@F) $@ 73355b4669Sjacobs 74355b4669Sjacobs# usr/lib links 75355b4669SjacobsROOTUSRLIBSYMLINKS = $(SBINPROGS:%=$(ROOTLIB)/%) 76355b4669Sjacobs$(ROOTLIB)/%: $(ROOTLIB) % 77355b4669Sjacobs 78355b4669Sjacobs$(ROOTUSRLIBSYMLINKS): 79355b4669Sjacobs $(RM) $@; $(SYMLINK) ../sbin/$(@F) $@ 80355b4669Sjacobs 81355b4669Sjacobs.KEEP_STATE: 82355b4669Sjacobs 83355b4669Sjacobsall: $(BINPROGS) $(SBINPROGS) 84355b4669Sjacobs 85355b4669Sjacobsinstall: $(BINPROGS) $(SBINPROGS) $(ROOTBINPROGS) $(ROOTUSRSBINPROGS) \ 86*0a44ef6dSjacobs $(ROOTLIBPRINT) $(ROOTLIBPRINTPROGS) $(ROOTMANIFEST) \ 87355b4669Sjacobs $(ROOTUCBSYMLINKS) $(ROOTUSRLIBSYMLINKS) 88355b4669Sjacobs 89*0a44ef6dSjacobscheck: $(CHKMANIFEST) 90*0a44ef6dSjacobs 91355b4669Sjacobsclean: 92355b4669Sjacobs $(RM) $(OBJS) 93355b4669Sjacobs 94*0a44ef6dSjacobsCLOBBERFILES += $(BINPROGS) $(SBINPROGS) $(LIBPRINTPROGS) 95355b4669Sjacobs 96355b4669Sjacobslint: 97355b4669Sjacobs 98355b4669Sjacobsinclude ../../Makefile.targ 99