Print this page
dccp: basic dtrace
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/lib/libdtrace/Makefile.com
+++ new/usr/src/lib/libdtrace/Makefile.com
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
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 (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved.
23 23 # Copyright (c) 2011 by Delphix. All rights reserved.
24 24 #
25 25
26 26 LIBRARY = libdtrace.a
27 27 VERS = .1
28 28
29 29 LIBSRCS = \
30 30 dt_aggregate.c \
31 31 dt_as.c \
32 32 dt_buf.c \
33 33 dt_cc.c \
34 34 dt_cg.c \
35 35 dt_consume.c \
36 36 dt_decl.c \
37 37 dt_dis.c \
38 38 dt_dof.c \
39 39 dt_error.c \
40 40 dt_errtags.c \
41 41 dt_handle.c \
42 42 dt_ident.c \
43 43 dt_inttab.c \
44 44 dt_link.c \
45 45 dt_list.c \
46 46 dt_open.c \
47 47 dt_options.c \
48 48 dt_program.c \
49 49 dt_map.c \
50 50 dt_module.c \
51 51 dt_names.c \
52 52 dt_parser.c \
53 53 dt_pcb.c \
54 54 dt_pid.c \
55 55 dt_pragma.c \
56 56 dt_print.c \
57 57 dt_printf.c \
58 58 dt_proc.c \
59 59 dt_provider.c \
60 60 dt_regset.c \
61 61 dt_string.c \
62 62 dt_strtab.c \
63 63 dt_subr.c \
64 64 dt_work.c \
65 65 dt_xlator.c
↓ open down ↓ |
65 lines elided |
↑ open up ↑ |
66 66
67 67 LIBISASRCS = \
68 68 dt_isadep.c
69 69
70 70 OBJECTS = dt_lex.o dt_grammar.o $(MACHOBJS) $(LIBSRCS:%.c=%.o) $(LIBISASRCS:%.c=%.o)
71 71
72 72 DRTISRC = drti.c
73 73 DRTIOBJ = $(DRTISRC:%.c=%.o)
74 74
75 75 DLIBSRCS += \
76 + dccp.d \
76 77 errno.d \
77 78 fc.d \
78 79 io.d \
79 80 ip.d \
80 81 iscsit.d \
81 82 net.d \
82 83 nfs.d \
83 84 nfssrv.d \
84 85 procfs.d \
85 86 regs.d \
86 87 sched.d \
87 88 signal.d \
88 89 scsi.d \
89 90 srp.d \
90 91 sysevent.d \
91 92 tcp.d \
92 93 udp.d \
93 94 unistd.d
94 95
95 96 include ../../Makefile.lib
96 97
97 98 SRCS = $(LIBSRCS:%.c=../common/%.c) $(LIBISASRCS:%.c=../$(MACH)/%.c)
98 99 LIBS = $(DYNLIB) $(LINTLIB)
99 100
100 101 SRCDIR = ../common
101 102
↓ open down ↓ |
16 lines elided |
↑ open up ↑ |
102 103 CLEANFILES += dt_lex.c dt_grammar.c dt_grammar.h y.output
103 104 CLEANFILES += ../common/procfs.sed ../common/procfs.d
104 105 CLEANFILES += ../common/io.sed ../common/io.d
105 106 CLEANFILES += ../common/ip.sed ../common/ip.d
106 107 CLEANFILES += ../common/net.sed ../common/net.d
107 108 CLEANFILES += ../common/errno.d ../common/signal.d
108 109 CLEANFILES += ../common/dt_errtags.c ../common/dt_names.c
109 110 CLEANFILES += ../common/sysevent.sed ../common/sysevent.d
110 111 CLEANFILES += ../common/tcp.sed ../common/tcp.d
111 112 CLEANFILES += ../common/udp.sed ../common/udp.d
113 +CLEANFILES += ../common/dccp.sed ../common/dccp.d
112 114
113 115 CLOBBERFILES += drti.o
114 116
115 117 CPPFLAGS += -I../common -I.
116 118 CFLAGS += $(CCVERBOSE) $(C_BIGPICFLAGS)
117 119 CFLAGS64 += $(CCVERBOSE) $(C_BIGPICFLAGS)
118 120 YYCFLAGS =
119 121 LDLIBS += -lgen -lproc -lrtld_db -lnsl -lsocket -lctf -lelf -lc
120 122 DRTILDLIBS = $(LDLIBS.lib) -lc
121 123
122 124 yydebug := YYCFLAGS += -DYYDEBUG
123 125
124 126 $(LINTLIB) := SRCS = $(SRCDIR)/$(LINTSRC)
125 127
126 128 LFLAGS = -t -v
127 129 YFLAGS = -d -v
128 130
129 131 ROOTDLIBDIR = $(ROOT)/usr/lib/dtrace
130 132 ROOTDLIBDIR64 = $(ROOT)/usr/lib/dtrace/64
131 133
132 134 ROOTDLIBS = $(DLIBSRCS:%=$(ROOTDLIBDIR)/%)
133 135 ROOTDOBJS = $(ROOTDLIBDIR)/$(DRTIOBJ)
134 136 ROOTDOBJS64 = $(ROOTDLIBDIR64)/$(DRTIOBJ)
135 137
136 138 .KEEP_STATE:
137 139
138 140 all: $(LIBS) $(DRTIOBJ)
139 141
140 142 lint: lintdrti lintcheck
141 143
142 144 lintdrti: ../common/$(DRTISRC)
143 145 $(LINT.c) ../common/$(DRTISRC) $(DRTILDLIBS)
144 146
145 147 dt_lex.c: $(SRCDIR)/dt_lex.l dt_grammar.h
146 148 $(LEX) $(LFLAGS) $(SRCDIR)/dt_lex.l > $@
147 149
148 150 dt_grammar.c dt_grammar.h: $(SRCDIR)/dt_grammar.y
149 151 $(YACC) $(YFLAGS) $(SRCDIR)/dt_grammar.y
150 152 @mv y.tab.h dt_grammar.h
151 153 @mv y.tab.c dt_grammar.c
152 154
153 155 pics/dt_lex.o pics/dt_grammar.o := CFLAGS += $(YYCFLAGS)
154 156 pics/dt_lex.o pics/dt_grammar.o := CFLAGS64 += $(YYCFLAGS)
155 157
156 158 pics/dt_lex.o pics/dt_grammar.o := CERRWARN += -erroff=E_STATEMENT_NOT_REACHED
157 159 pics/dt_lex.o pics/dt_grammar.o := CCVERBOSE =
158 160
159 161 ../common/dt_errtags.c: ../common/mkerrtags.sh ../common/dt_errtags.h
160 162 sh ../common/mkerrtags.sh < ../common/dt_errtags.h > $@
161 163
162 164 ../common/dt_names.c: ../common/mknames.sh $(SRC)/uts/common/sys/dtrace.h
163 165 sh ../common/mknames.sh < $(SRC)/uts/common/sys/dtrace.h > $@
164 166
165 167 ../common/errno.d: ../common/mkerrno.sh $(SRC)/uts/common/sys/errno.h
166 168 sh ../common/mkerrno.sh < $(SRC)/uts/common/sys/errno.h > $@
167 169
168 170 ../common/signal.d: ../common/mksignal.sh $(SRC)/uts/common/sys/iso/signal_iso.h
169 171 sh ../common/mksignal.sh < $(SRC)/uts/common/sys/iso/signal_iso.h > $@
170 172
171 173 ../common/%.sed: ../common/%.sed.in
172 174 $(COMPILE.cpp) -D_KERNEL $< | tr -d ' ' | tr '"' '@' | \
173 175 sed 's/\&/\\\&/g' | grep '^s/' > $@
174 176
175 177 ../common/procfs.d: ../common/procfs.sed ../common/procfs.d.in
176 178 sed -f ../common/procfs.sed < ../common/procfs.d.in > $@
177 179
178 180 ../common/io.d: ../common/io.sed ../common/io.d.in
179 181 sed -f ../common/io.sed < ../common/io.d.in > $@
180 182
181 183 ../common/ip.d: ../common/ip.sed ../common/ip.d.in
182 184 sed -f ../common/ip.sed < ../common/ip.d.in > $@
183 185
184 186 ../common/net.d: ../common/net.sed ../common/net.d.in
185 187 sed -f ../common/net.sed < ../common/net.d.in > $@
↓ open down ↓ |
64 lines elided |
↑ open up ↑ |
186 188
187 189 ../common/sysevent.d: ../common/sysevent.sed ../common/sysevent.d.in
188 190 sed -f ../common/sysevent.sed < ../common/sysevent.d.in > $@
189 191
190 192 ../common/tcp.d: ..//common/tcp.sed ../common/tcp.d.in
191 193 sed -f ../common/tcp.sed < ../common/tcp.d.in > $@
192 194
193 195 ../common/udp.d: ../common/udp.sed ../common/udp.d.in
194 196 sed -f ../common/udp.sed < ../common/udp.d.in > $@
195 197
198 +../common/dccp.d: ../common/dccp.sed ../common/dccp.d.in
199 + sed -f ../common/dccp.sed < ../common/dccp.d.in > $@
200 +
196 201 pics/%.o: ../$(MACH)/%.c
197 202 $(COMPILE.c) -o $@ $<
198 203 $(POST_PROCESS_O)
199 204
200 205 pics/%.o: ../$(MACH)/%.s
201 206 $(COMPILE.s) -o $@ $<
202 207 $(POST_PROCESS_O)
203 208
204 209 %.o: ../common/%.c
205 210 $(COMPILE.c) -o $@ $<
206 211 $(POST_PROCESS_O)
207 212
208 213 $(ROOTDLIBDIR):
209 214 $(INS.dir)
210 215
211 216 $(ROOTDLIBDIR64): $(ROOTDLIBDIR)
212 217 $(INS.dir)
213 218
214 219 $(ROOTDLIBDIR)/%.d: ../common/%.d
215 220 $(INS.file)
216 221
217 222 $(ROOTDLIBDIR)/%.d: ../$(MACH)/%.d
218 223 $(INS.file)
219 224
220 225 $(ROOTDLIBDIR)/%.d: %.d
221 226 $(INS.file)
222 227
223 228 $(ROOTDLIBDIR)/%.o: %.o
224 229 $(INS.file)
225 230
226 231 $(ROOTDLIBDIR64)/%.o: %.o
227 232 $(INS.file)
228 233
229 234 $(ROOTDLIBS): $(ROOTDLIBDIR)
230 235
231 236 $(ROOTDOBJS): $(ROOTDLIBDIR)
232 237
233 238 $(ROOTDOBJS64): $(ROOTDLIBDIR64)
234 239
235 240 include ../../Makefile.targ
↓ open down ↓ |
30 lines elided |
↑ open up ↑ |
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX