xref: /titanic_50/usr/src/cmd/troff/troff.d/Makefile (revision 080575042aba2197b425ebfd52061dea061a9aa1)
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# ident	"%Z%%M%	%I%	%E% SMI"
24#
25# Copyright (c) 1989 by Sun Microsystems, Inc.
26#
27# cmd/troff/troff.d/Makefile
28#
29
30include 	../../Makefile.cmd
31
32PROG =		troff ta makedev
33
34SUBDIRS =	tmac.d devaps
35
36TAOBJS =	draw.o ta.o
37MAKEDEVOBJS =	makedev.o
38TROFFOBJS =	t10.o t6.o
39COMMONOBJS =	hytab.o n1.o n2.o n3.o n4.o n5.o		\
40		n7.o n8.o n9.o ni.o nii.o suftab.o
41
42SRCS =		$(TAOBJS:%.o=%.c) $(MAKEDEVOBJS:%.o=%.c)	\
43		$(TROFFOBJS:%.o=%.c) $(COMMONOBJS:%.o=../%.c)
44
45TXTS =		README maketables troff.sh
46
47CPPFLAGS =	-DUSG -DINCORE -I. -I.. $(CPPFLAGS.master)
48#
49# For message catalog
50#
51POFILES= $(TROFFOBJS:%.o=%.po) $(COMMONOBJS:%.o=../%.po)
52POFILE= troff.d.po
53
54# conditional assignments
55
56all :=		TARGET= all
57install :=	TARGET= install
58clean :=	TARGET= clean
59clobber :=	TARGET= clobber
60lint :=		TARGET= lint
61strip :=	TARGET= strip
62
63troff:=		POBJS=	$(COMMONOBJS) $(TROFFOBJS)
64ta:=		POBJS=	$(TAOBJS)
65makedev:=	POBJS=	$(MAKEDEVOBJS)
66
67ta:=		LDLIBS += -lm
68troff:=		LDLIBS += -lmapmalloc
69
70# build rule for common source above
71%.o: ../%.c
72		$(COMPILE.c) $<
73
74.KEEP_STATE:
75
76.PARALLEL: $(COMMONOBJS) $(TROFFOBJS) $(TAOBJS) $(MAKEDEVOBJS)
77
78all :		$(PROG) $(TXTS) $(SUBDIRS)
79
80$(PROG) :	$$(POBJS)
81		$(LINK.c) -o $@ $(POBJS) $(LDLIBS)
82		$(POST_PROCESS)
83
84install:	$(PROG) $(ROOTPROG) $(SUBDIRS)
85
86clean:		$(SUBDIRS)
87		$(RM) $(TAOBJS) $(MAKEDEVOBJS) $(TROFFOBJS) $(COMMONOBJS)
88
89catalog:        $(POFILE)
90
91$(POFILE):      $(POFILES)
92	$(RM)	$@
93	cat     $(POFILES)      > $@
94
95
96strip :
97		$(STRIP $(PROG)
98
99lint :		lint_SRCS
100
101include		../../Makefile.targ
102
103# additional dependency for clobber which is defined in Makefile.targ
104clobber:	$(SUBDIRS)
105
106$(SUBDIRS) :	FRC
107		@cd $@; pwd; $(MAKE) $(TARGET)
108
109FRC:
110