Print this page
10080 smatch Makefile changes for usr/src/cmd
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/cmd/saf/Makefile
+++ new/usr/src/cmd/saf/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.
25 26
26 27 PROG= sac sacadm pmadm
27 28
28 29 MANIFEST = sac.xml
29 30
30 31 include ../Makefile.cmd
31 32
32 33 ROOTMANIFESTDIR = $(ROOTSVCSYSTEM)
33 34
34 35 SACOBJ= sac.o readtab.o global.o log.o misc.o
35 36 SACOBJS= $(SACOBJ) util1.o
36 37 SACADMOBJ= sacadm.o admutil.o
37 38 SACADMOBJS= $(SACADMOBJ) util2.o
38 39 PMADMOBJ= pmadm.o admutil.o
39 40 PMADMOBJS= $(PMADMOBJ) util2.o
40 41 SACSRC= $(SACOBJ:%.o=%.c)
41 42 SACSRCS= $(SACSRC) util.c
42 43 SACADMSRC= $(SACADMOBJ:%.o=%.c)
43 44 SACADMSRCS= $(SACADMSRC) util.c
44 45 PMADMSRC= $(PMADMOBJ:%.o=%.c)
45 46 PMADMSRCS= $(PMADMSRC) util.c
46 47 OBJS= $(SACOBJS) $(SACADMOBJS) $(PMADMOBJS)
47 48
48 49 LIBSAFD = $(ROOTLIB)/saf
49 50 DIRS= $(LIBSAFD)
50 51 SACF= sac
51 52 ADMF= sacadm pmadm
52 53 ROOTSACF= $(SACF:%=$(LIBSAFD)/%)
53 54 ROOTADMF= $(ADMF:%=$(ROOTUSRSBIN)/%)
↓ open down ↓ |
19 lines elided |
↑ open up ↑ |
54 55
55 56 LDLIBS += -lnsl
56 57 LDFLAGS += $(MAPFILE.NGB:%=-M%)
57 58 LINTFLAGS += -b -x
58 59
59 60 CERRWARN += -_gcc=-Wno-implicit-function-declaration
60 61 CERRWARN += -_gcc=-Wno-parentheses
61 62 CERRWARN += -_gcc=-Wno-unused-variable
62 63 CERRWARN += -_gcc=-Wno-extra
63 64
65 +# too many untyped funcs
66 +SMATCH=off
67 +
64 68 util1.o := CPPFLAGS += -DSAC
65 69 util2.o := CPPFLAGS += -USAC
66 70
67 71 sac := LDLIBS += -lpam
68 72
69 73 $(ROOTUSRSBIN)/sacadm := FILEMODE = 04755
70 74
71 75 $(LIBSAFD)/% : %
72 76 $(INS.file)
73 77
74 78 .KEEP_STATE:
75 79
76 80 .PARALLEL: $(OBJS)
77 81
78 82 all: $(PROG)
79 83
80 84 sac: $(SACOBJS) $(MAPFILE.NGB)
81 85 $(LINK.c) $(SACOBJS) -o $@ $(LDLIBS)
82 86 $(POST_PROCESS)
83 87
84 88 sacadm: $(SACADMOBJS) $(MAPFILE.NGB)
85 89 $(LINK.c) $(SACADMOBJS) -o $@ $(LDLIBS)
86 90 $(POST_PROCESS)
87 91
88 92 pmadm: $(PMADMOBJS) $(MAPFILE.NGB)
89 93 $(LINK.c) $(PMADMOBJS) -o $@ $(LDLIBS)
90 94 $(POST_PROCESS)
91 95
92 96 util1.o: util.c
93 97 $(COMPILE.c) -o $@ util.c
94 98
95 99 util2.o: util.c
96 100 $(COMPILE.c) -o $@ util.c
97 101
98 102 install: all .WAIT $(ROOTSACF) $(ROOTADMF) $(ROOTMANIFEST)
99 103
100 104 # Don't install dirs already installed by Targetdirs
101 105 #$(DIRS):
102 106 # $(INS.dir)
103 107
104 108 check: $(CHKMANIFEST)
105 109
106 110 clean:
107 111 $(RM) $(OBJS)
108 112
109 113 lint:
110 114 $(LINT.c) $(SACSRCS)
111 115 $(LINT.c) $(SACADMSRCS)
112 116 $(LINT.c) $(PMADMSRCS)
113 117
114 118 include ../Makefile.targ
↓ open down ↓ |
41 lines elided |
↑ open up ↑ |
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX