Print this page
10080 smatch Makefile changes for usr/src/cmd
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/cmd/ksh/builtins/Makefile
+++ new/usr/src/cmd/ksh/builtins/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.
15 15 # If applicable, add the following below this CDDL HEADER, with the
↓ open down ↓ |
15 lines elided |
↑ open up ↑ |
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 #
23 23 # Copyright 2009 Sun Microsystems, Inc. All rights reserved.
24 24 # Use is subject to license terms.
25 25 #
26 -
27 -#
28 26 # Copyright 2010 Nexenta Systems, Inc. All rights reserved.
29 27 #
28 +# Copyright (c) 2018, Joyent, Inc.
29 +#
30 30
31 31 PROG= alias
32 32 ALIASPROG= \
33 33 bg \
34 34 cd \
35 35 cksum \
36 36 cmp \
37 37 comm \
38 38 command \
39 39 cut \
40 40 fc \
41 41 fg \
42 42 getopts \
43 43 hash \
44 44 jobs \
45 45 join \
46 46 kill \
47 47 logname \
48 48 paste \
49 49 print \
50 50 read \
51 51 rev \
52 52 sleep \
53 53 sum \
54 54 tee \
55 55 test \
56 56 type \
57 57 ulimit \
58 58 umask \
59 59 unalias \
60 60 uniq \
61 61 wait \
62 62 wc
63 63
64 64 XPG4ALIASPROG= \
65 65 alias \
66 66 bg \
67 67 cd \
68 68 command \
69 69 fc \
70 70 fg \
71 71 getopts \
72 72 hash \
73 73 jobs \
74 74 kill \
75 75 read \
76 76 test \
77 77 type \
78 78 ulimit \
79 79 umask \
80 80 unalias \
81 81 wait
82 82
83 83 XPG4SH= \
84 84 sh
85 85
↓ open down ↓ |
46 lines elided |
↑ open up ↑ |
86 86 ROOTXPG4ALIAS= \
87 87 $(XPG4SH:%=$(ROOTXPG4BIN)/%) $(XPG4ALIASPROG:%=$(ROOTXPG4BIN)/%)
88 88 ROOTALIASPROG= $(ALIASPROG:%=$(ROOTBIN)/%)
89 89
90 90 include ../../Makefile.cmd
91 91 $(SPARC_BLD)include ../../Makefile.cmd.64
92 92
93 93 FILEMODE= 555
94 94 CERRWARN += -_gcc=-Wno-parentheses
95 95
96 +# not linted
97 +SMATCH=off
98 +
96 99 .KEEP_STATE:
97 100
98 101 all: $(PROG)
99 102
100 103 $(XPG4ALIASPROG:%=$(ROOTXPG4BIN)/%):
101 104 $(RM) $@; $(SYMLINK) ../../bin/alias $@
102 105
103 106 $(XPG4SH:%=$(ROOTXPG4BIN)/%):
104 107 $(RM) $@; $(SYMLINK) ../../bin/ksh93 $@
105 108
106 109 $(ALIASPROG:%=$(ROOTBIN)/%): $(ROOTPROG)
107 110 $(RM) $@; $(LN) $(ROOTPROG) $@
108 111
109 112 .KEEP_STATE:
110 113
111 114 # Set common AST build flags (e.g., needed to support the math stuff).
112 115 include ../../../Makefile.ast
113 116
114 117 OBJECTS= \
115 118 alias.o
116 119
117 120 SRCS= $(OBJECTS:%.o=%.c)
118 121
119 122 LDLIBS += -lshell -lcmd -last
120 123
121 124 CPPFLAGS = \
122 125 $(DTEXTDOM) $(DTS_ERRNO) \
123 126 -I$(ROOT)/usr/include/ast \
124 127 -I$(ROOT)/usr/include
125 128
126 129 # Enable workaround for a crash in /usr/bin/alias when invalid
127 130 # options are passed (e.g. $ /usr/bin/alias -c #). The shell
128 131 # code will call an error handler which does a |longjmp()| but
129 132 # somehow the code failed to do the |setjmp()| before this point.
130 133 CPPFLAGS += -DWORKAROUND_FOR_ALIAS_CRASH
131 134
132 135 CFLAGS += \
133 136 $(ASTCFLAGS)
134 137 CFLAGS64 += \
135 138 $(ASTCFLAGS64)
136 139
137 140 ROOTCMDDIR=$(ROOT)/usr/bin
138 141
139 142 install: all $(ROOTPROG) $(ROOTXPG4PROG) $(ROOTALIASPROG) $(ROOTXPG4ALIAS)
140 143
141 144 $(PROG): $(OBJECTS)
142 145 $(RM) alias
143 146 $(LINK.c) $(OBJECTS) -o $@ $(LDLIBS)
144 147 $(POST_PROCESS)
145 148
146 149 clean clobber:
147 150 rm -f $(PROG) $(OBJECTS)
148 151
149 152 lint _msg:
↓ open down ↓ |
44 lines elided |
↑ open up ↑ |
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX