Print this page
10080 smatch Makefile changes for usr/src/cmd
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/cmd/mail/Makefile
+++ new/usr/src/cmd/mail/Makefile
1 1 #
2 2 # CDDL HEADER START
3 3 #
4 4 # The contents of this file are subject to the terms of the
5 5 # Common Development and Distribution License (the "License").
6 6 # You may not use this file except in compliance with the License.
7 7 #
8 8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 9 # or http://www.opensolaris.org/os/licensing.
10 10 # See the License for the specific language governing permissions
11 11 # and limitations under the License.
12 12 #
13 13 # When distributing Covered Code, include this CDDL HEADER in each
14 14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
↓ open down ↓ |
14 lines elided |
↑ open up ↑ |
15 15 # If applicable, add the following below this CDDL HEADER, with the
16 16 # fields enclosed by brackets "[]" replaced with your own identifying
17 17 # information: Portions Copyright [yyyy] [name of copyright owner]
18 18 #
19 19 # CDDL HEADER END
20 20 #
21 21 #
22 22 # Copyright 2009 Sun Microsystems, Inc. All rights reserved.
23 23 # Use is subject to license terms.
24 24 #
25 +# Copyright (c) 2018, Joyent, Inc.
26 +#
25 27
28 +BINPROG= mail
26 29
27 -BINPROG= mail
28 -
29 30 PROG= $(BINPROG)
30 31
31 32 GREP= grep
32 33
33 34 include ../Makefile.cmd
34 35
35 36 CLOBBERFILES= $(PROG)
36 37 CLEANFILES= $(MAILOBJS)
37 38
38 39 MAILOBJS= add_recip.o cat.o ckdlivopts.o \
39 40 cksaved.o clr_hinfo.o copyback.o copylet.o \
40 41 copymt.o createmf.o del_recipl.o Dout.o delete.o \
41 42 done.o doopen.o dumpaff.o dumprcv.o \
42 43 errmsg.o gendeliv.o getarg.o getcomment.o \
43 44 gethead.o goback.o init.o \
44 45 isheader.o isit.o islocal.o istext.o legal.o \
45 46 lock.o main.o mkdead.o mta_ercode.o \
46 47 new_recipl.o parse.o pckaffspot.o pckrcvspot.o \
47 48 pickFrom.o pipletr.o poplist.o printhdr.o printmail.o \
48 49 pushlist.o savehdrs.o sel_disp.o sendlist.o \
49 50 sendmail.o setsig.o \
50 51 stamp.o Tout.o
51 52
52 53 MAILSRC= $(MAILOBJS:%.o=%.c)
53 54
54 55 CPROG= mail
55 56 CPROGSRC= $(CPROG:%=_%.c)
56 57
57 58 # ROOT directories
58 59 ROOTMAILD= $(ROOTLIB)/mail
59 60 ROOTINC= $(ROOT)/usr/include
60 61
61 62 # installed modules
62 63 ROOTBINPROG= $(BINPROG:%=$(ROOTBIN)/%)
63 64
64 65 ROOTSYMLINKS= $(ROOTBIN)/rmail
65 66
66 67
67 68 EDITPATH= \
68 69 sed -e 's!REAL_PATH!/usr/bin!g' \
↓ open down ↓ |
30 lines elided |
↑ open up ↑ |
69 70 -e 's!USR_SHARE_LIB!/usr/share/lib!g' \
70 71 -e 's!VAR_MAIL!/var/mail!g' < $? > $@
71 72
72 73 CPPFLAGS = -DSVR4 -I. $(CPPFLAGS.master)
73 74 CERRWARN += -_gcc=-Wno-implicit-function-declaration
74 75 CERRWARN += -_gcc=-Wno-unused-variable
75 76 CERRWARN += -_gcc=-Wno-uninitialized
76 77 CERRWARN += -_gcc=-Wno-clobbered
77 78 CERRWARN += -_gcc=-Wno-extra
78 79
80 +# missing type declarations for old-style functions
81 +SMATCH = off
82 +
79 83 LDLIBS += -lmail -lsocket
80 84
81 85 # mail defines its own delete() - reduce symbols to locals to remove name clash.
82 86 LDFLAGS += $(MAPFILE.NGB:%=-M%)
83 87
84 88 # conditional assignments
85 89 #
86 90 all:= TARGET= all
87 91 install:= TARGET= install
88 92 clean:= TARGET= clean
89 93 clobber:= TARGET= clobber
90 94 lint:= TARGET= lint
91 95
92 96 # file modes, owners and groups for the install target
93 97 #
94 98
95 99
96 100 $(ROOTBIN)/mail := FILEMODE = 02511
↓ open down ↓ |
8 lines elided |
↑ open up ↑ |
97 101
98 102
99 103 # install rules
100 104 $(ROOTINC)/% : %
101 105 $(INS.file)
102 106
103 107 .KEEP_STATE:
104 108
105 109 .PARALLEL: $(MAILOBJS) $(OBJS)
106 110
107 -all: $(PROG)
111 +all: $(PROG)
108 112
109 113 mail: $(MAILOBJS)
110 114 $(LINK.c) -o $@ $(MAILOBJS) $(LDLIBS)
111 115 $(POST_PROCESS)
112 116
113 117 install: all .WAIT $(ROOTBINPROG) $(ROOTSYMLINKS)
114 118
115 119 # ROOTSYMLINKS
116 120 #
117 121 $(ROOTBIN)/rmail:
118 122 $(RM) $@; $(SYMLINK) mail $@
119 123
120 -lint:
124 +lint:
121 125 $(LINT.c) $(MAILSRC)
122 126
123 127 clean:
124 128 $(RM) $(OBJS) $(MAILOBJS)
125 129
126 130 clobber:
127 131 $(RM) $(OBJS) $(MAILOBJS) mail
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX