xref: /illumos-gate/usr/src/lib/print/Makefile (revision d1aea6f139360e9e7f1504facb24f8521047b15c)
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 2006 Sun Microsystems, Inc.  All rights reserved.
23# Use is subject to license terms.
24#
25
26include $(SRC)/Makefile.master
27
28SUBDIRS = \
29	libprint \
30	libpapi-common \
31	libpapi-dynamic \
32	libpapi-lpd \
33	libipp-core \
34	libhttp-core \
35	libpapi-ipp \
36	libipp-listener
37
38all :=                  TARGET = all
39clean :=                TARGET = clean
40clobber :=              TARGET = clobber
41install :=              TARGET = install
42install_h :=              TARGET = install_h
43lint :=                 TARGET = lint
44
45TEXT_DOMAIN=	SUNW_OST_OSLIB
46POFILE= print-lib.po
47
48.KEEP_STATE:
49
50all:	$(TXTS) $(SUBDIRS)
51
52#
53# Each message catalog file is generated in each sub
54# directory and copied to the usr/src/cmd/lp/ directory.
55# Those message catalog files are consolidated into one
56# message catalog file.  The consolidated one will be copied
57# into the $(ROOT)/catalog/SUNW_OST_OSCMD/ directory.
58#
59
60_msg:	$(MSGDOMAIN)
61	@$(RM) $(POFILE)
62	$(XGETTEXT) -s `/bin/find . -type d -name SCCS -prune -o -type f -name '*.c' -print`
63	@/bin/cat messages.po | sed '/domain/d' > $(POFILE)
64	@$(RM) messages.po
65	$(RM)  $(MSGDOMAIN)/$(POFILE)
66	/bin/cp $(POFILE) $(MSGDOMAIN)
67
68install: $(ROOTDIRS) $(ROOTSYMLINKDIRS) $(SUBDIRS)
69
70install_h clean strip lint: $(SUBDIRS)
71
72clobber: $(SUBDIRS) local_clobber
73
74local_clobber:
75	$(RM) $(CLOBBERFILES) $(POFILE)
76
77$(SUBDIRS):	FRC
78	@cd $@; pwd; $(MAKE) $(TARGET)
79
80FRC:
81
82include $(SRC)/Makefile.msg.targ
83
84# Dependencies
85libpapi-dynamic:	libpapi-common
86libpapi-lpd:		libpapi-dynamic
87libipp-core:		libpapi-common
88libpapi-ipp:		libpapi-common libipp-core libhttp-core
89libipp-listener:	libpapi-dynamic libipp-core
90