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# 23# Copyright 2007 Sun Microsystems, Inc. All rights reserved. 24# Use is subject to license terms. 25# 26 27# 28# ident "%Z%%M% %I% %E% SMI" 29# 30 31include ../Makefile.lp 32 33OWNER = root 34 35SUBDIRS = lptest lpadmin lpsched scripts 36 37LOCALPROG = lpshut 38 39SBINPROG = lpfilter lpforms lpusers 40 41LIBLINKS = $(SBINPROG) 42 43PROG = $(LOCALPROG) $(SBINPROG) 44 45OBJS= $(SBINPROG:=.o) 46 47SRCS= $(OBJS:.o=.c) 48 49POFILE= lp_cmd.po 50POFILES= $(SRCS:%.c=%.po) lpschedlpshut.po 51 52ROOTLIBLPLOCLPROG= $(LOCALPROG:%=$(ROOTLIBLPLOCL)/%) 53ROOTSBINPROG= $(SBINPROG:%=$(ROOTUSRSBIN)/%) 54ROOTSYMLINKS= $(LIBLINKS:%=$(ROOTLIB)/%) 55 56 57CPPFLAGS = -I$(LPINC) $(CPPFLAGS.master) 58LDFLAGS += $(MAPFILE.NGB:%=-M%) 59 60# conditional assignments 61# 62lpfilter:= LDLIBS += $(LIBFLT) $(LIBMSG) $(LIBACC) $(LIBOAM) $(LIBLP) \ 63 -lgen $(ZLAZYLOAD) -lsecdb $(ZNOLAZYLOAD) 64lpforms:= LDLIBS += $(LIBFRM) $(LIBMSG) $(LIBREQ) $(LIBOAM) \ 65 $(LIBACC) $(LIBLP) \ 66 $(ZLAZYLOAD) -lsecdb $(ZNOLAZYLOAD) 67lpshut:= LDLIBS += $(LIBMSG) $(LIBOAM) $(LIBLP) 68lpusers:= LDLIBS += $(LIBMSG) $(LIBACC) $(LIBOAM) $(LIBUSR) $(LIBLP) 69 70.KEEP_STATE: 71 72all: $(PROG) $(SUBDIRS) 73 74install: $(PROG) $(ROOTLIBLPLOCLPROG) $(ROOTSBINPROG) \ 75 $(ROOTSYMLINKS) $(SUBDIRS) 76 77catalog: $(SUBDIRS) $(POFILE) 78 $(CP) $(POFILE) .. 79 80clean: $(SUBDIRS) 81 $(RM) $(OBJS) 82 83clobber: $(SUBDIRS) local_clobber 84 85local_clobber: 86 $(RM) $(OBJS) $(PROG) $(CLOBBERFILES) 87 88strip: $(SUBDIRS) 89 $(STRIP) $(PROG) 90 91lint: 92 $(LINT.c) $(SRCS) $(LDLIBS) 93 94$(ROOTSYMLINKS): 95 $(RM) $@; $(SYMLINK) ../sbin/$(@F) $@ 96 97$(SUBDIRS): FRC 98 @cd $@; pwd; $(MAKE) $(TARGET) 99 100include ../Makefile.lp.msg 101 102FRC: 103