xref: /titanic_50/usr/src/cmd/lp/Makefile (revision 1ae0874509b6811fdde1dfd46f0d93fd09867a3f)
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, Version 1.0 only
6# (the "License").  You may not use this file except in compliance
7# with the License.
8#
9# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10# or http://www.opensolaris.org/os/licensing.
11# See the License for the specific language governing permissions
12# and limitations under the License.
13#
14# When distributing Covered Code, include this CDDL HEADER in each
15# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16# If applicable, add the following below this CDDL HEADER, with the
17# fields enclosed by brackets "[]" replaced with your own identifying
18# information: Portions Copyright [yyyy] [name of copyright owner]
19#
20# CDDL HEADER END
21#
22#
23# Copyright 2004 Sun Microsystems, Inc.  All rights reserved.
24# Use is subject to license terms.
25#
26# ident	"%Z%%M%	%I%	%E% SMI"
27#
28
29include 	./Makefile.lp
30
31SUBDIRS =	etc filter crontab terminfo lib cmd model
32
33MSGSUBDIRS =	filter lib cmd model
34
35ROOTDIRS =					\
36		$(ROOTLIBLP)			\
37		$(ROOTLIBLP)/bin		\
38		$(ROOTLIBLP)/model		\
39		$(ROOTLIBLPLOCL)		\
40		$(ROOTLIB)/print		\
41		$(ROOTLIB)/print/bsd-adaptor	\
42		$(LPOWNSDIRS)
43LPOWNSDIRS =					\
44		$(ROOTETCLP)			\
45		$(ROOTETCLP)/classes		\
46		$(ROOTETCLP)/forms		\
47		$(ROOTETCLP)/interfaces		\
48		$(ROOTETCLP)/printers		\
49		$(ROOTETCLP)/pwheels		\
50		$(ROOTETCLP)/ppd		\
51		$(ROOTVAR)/lp			\
52		$(ROOTVAR)/lp/logs		\
53		$(ROOTVARSP)/lp			\
54		$(ROOTVARSP)/lp/admins		\
55		$(ROOTVARSP)/lp/requests 	\
56		$(ROOTVARSP)/lp/system
57
58SYMDIR1 =	$(ROOTVARSP)/lp/admins/lp
59SYMDIR2 =	$(ROOTVARSP)/lp/bin
60SYMDIR3 =	$(ROOTVARSP)/lp/logs
61SYMDIR4 =	$(ROOTETCLP)/logs
62SYMDIR5 =	$(ROOTVARSP)/lp/model
63
64$(SYMDIR1) :=	SYMLNKDEST =	../../../../etc/lp
65$(SYMDIR2) :=	SYMLNKDEST =	../../../usr/lib/lp/bin
66$(SYMDIR3) :=	SYMLNKDEST =	../../lp/logs
67$(SYMDIR4) :=	SYMLNKDEST =	../../var/lp/logs
68$(SYMDIR5) :=	SYMLNKDEST =	../../../usr/lib/lp/model
69
70ROOTSYMLINKDIRS =	$(SYMDIR1) $(SYMDIR2) $(SYMDIR3) $(SYMDIR4) $(SYMDIR5)
71
72$(ROOTVAR)/lp :=		DIRMODE = 775
73$(ROOTVAR)/lp/logs :=		DIRMODE = 775
74$(ROOTETCLP) :=			DIRMODE = 775
75$(ROOTETCLP)/classes :=		DIRMODE = 775
76$(ROOTETCLP)/forms :=		DIRMODE = 775
77$(ROOTETCLP)/interfaces :=	DIRMODE = 775
78$(ROOTETCLP)/printers :=	DIRMODE = 775
79$(ROOTETCLP)/pwheels :=		DIRMODE = 775
80$(ROOTETCLP)/ppd :=		DIRMODE = 775
81$(ROOTVARSP)/lp :=		DIRMODE = 775
82$(ROOTVARSP)/lp/admins :=	DIRMODE = 775
83$(ROOTVARSP)/lp/requests :=	DIRMODE = 775
84$(ROOTVARSP)/lp/system :=	DIRMODE = 775
85$(LPOWNSDIRS) :=		OWNER = lp
86$(LPOWNSDIRS) :=		GROUP = lp
87$(ROOTLIB)/print :=		DIRMODE = 0755
88$(ROOTLIB)/print/bsd-adaptor :=	DIRMODE = 0755
89
90POFILE= lp.po
91POFILES= lp_*.po
92
93.KEEP_STATE:
94
95all:	$(TXTS) $(SUBDIRS)
96
97#
98# Each message catalog file is generated in each sub
99# directory and copied to the usr/src/cmd/lp/ directory.
100# Those message catalog files are consolidated into one
101# message catalog file.  The consolidated one will be copied
102# into the $(ROOT)/catalog/SUNW_OST_OSCMD/ directory.
103#
104
105_msg:	$(MSGDOMAINPOFILE)
106
107$(POFILE):	$(MSGSUBDIRS) pofile_POFILES
108
109install: $(ROOTDIRS) $(ROOTSYMLINKDIRS) $(SUBDIRS)
110
111clean strip lint: $(SUBDIRS)
112
113clobber: $(SUBDIRS) local_clobber
114
115local_clobber:
116	$(RM) $(CLOBBERFILES)
117
118$(ROOTDIRS) :
119	$(INS.dir)
120
121$(ROOTSYMLINKDIRS) :
122	-$(RM) $@; $(SYMLINK) $(SYMLNKDEST) $@
123
124$(SUBDIRS):	FRC
125	@cd $@; pwd; $(MAKE) $(TARGET)
126
127FRC:
128
129include $(SRC)/Makefile.msg.targ
130