xref: /titanic_52/usr/src/cmd/csh/Makefile (revision 24fe0b3bf671e123467ce1df0b67cadd3614c8e4)
1# Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
2# Use is subject to license terms.
3
4#	Copyright (c) 1983, 1984, 1985, 1986, 1987, 1988, 1989 AT&T
5#	  All Rights Reserved
6
7# Copyright (c) 1980 Regents of the University of California.
8# All rights reserved.  The Berkeley Software License Agreement
9# specifies the terms and conditions for redistribution.
10
11# ident	"%Z%%M%	%I%	%E% SMI"
12
13#
14# C Shell with process control; VM/UNIX VAX Makefile
15# Bill Joy UC Berkeley; Jim Kulp IIASA, Austria
16#
17
18include ../Makefile.cmd
19
20ED= ed
21#
22# For message catalogue files
23#
24GREP= egrep
25SED= sed
26POFILE= csh.po
27CLOBBERFILES += sh.tconst.h
28CLEANFILES += sh.tconst.h
29
30all :=          TARGET = all
31install :=      TARGET = install
32clean :=        TARGET = clean
33clobber :=      TARGET = clobber
34lint :=         TARGET = lint
35
36POBJS = \
37sh.o sh.char.o \
38sh.dir.o sh.dol.o sh.err.o sh.exec.o sh.exp.o\
39sh.file.o sh.func.o sh.glob.o sh.hist.o\
40sh.init.o sh.lex.o sh.misc.o sh.parse.o\
41sh.print.o sh.proc.o sh.sem.o sh.set.o\
42sh.tchar.o sh.time.o wait3.o printf.o
43
44CPPFLAGS +=	-D_FILE_OFFSET_BITS=64
45CPPFLAGS +=	-I ../sh
46
47.KEEP_STATE:
48
49all install clean clobber lint:	$(MACH)
50
51POFILES= $(POBJS:%.o=%.po)
52
53XGETFLAGS += -a -x csh.xcl
54
55#
56# For message catalogue files
57#
58_msg: $(MSGDOMAIN) sh.tconst.h .WAIT $(POFILE)
59	$(RM) $(POFILE)
60	cat $(POFILES) > $(POFILE)
61	$(RM) $(MSGDOMAIN)/$(POFILE)
62	$(CP) $(POFILE) $(MSGDOMAIN)
63
64$(MSGDOMAIN):
65	$(INS.dir)
66
67$(POFILE):	$(POFILES)
68	$(RM) $@; cat $(POFILES) > $@
69
70sh.tconst.h: sh.tconst.c make.sh.tconst.h.ed
71	$(RM) $@; $(ED) sh.tconst.c < make.sh.tconst.h.ed
72
73clobber: local_clobber $(MACH)
74
75local_clobber:
76	$(RM) $(CLOBBERFILES)
77
78clean: local_clean
79
80local_clean:
81	$(RM) $(CLEANFILES)
82
83$(MACH): sh.tconst.h .WAIT FRC
84	@cd $@; pwd; $(MAKE) $(TARGET)
85
86FRC:
87