xref: /titanic_44/usr/src/lib/libdtrace_jni/Makefile.com (revision 587032cf0967234b39ccb50adca936a367841063)
1#
2# CDDL HEADER START
3#
4# The contents of this file are subject to the terms of the
5# Common Development and Distribution License (the "License").
6# You may not use this file except in compliance with the License.
7#
8# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9# or http://www.opensolaris.org/os/licensing.
10# See the License for the specific language governing permissions
11# and limitations under the License.
12#
13# When distributing Covered Code, include this CDDL HEADER in each
14# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15# If applicable, add the following below this CDDL HEADER, with the
16# fields enclosed by brackets "[]" replaced with your own identifying
17# information: Portions Copyright [yyyy] [name of copyright owner]
18#
19# CDDL HEADER END
20#
21
22#
23# Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
24# Use is subject to license terms.
25#
26# ident	"%Z%%M%	%I%	%E% SMI"
27#
28
29LIBRARY = libdtrace_jni.a
30VERS = .1
31
32LIBSRCS = \
33	dtj_util.c \
34	dtj_jnitab.c \
35	dtj_error.c \
36	dtj_probe.c \
37	dtj_attr.c \
38	dtj_consume.c \
39	dtrace_jni.c
40
41OBJECTS = $(MACHOBJS) $(LIBSRCS:%.c=%.o)
42
43include ../../Makefile.lib
44
45SRCS = $(LIBSRCS:%.c=../common/%.c)
46
47SRCDIR = ../common
48SPECMAPFILE = $(MAPDIR)/mapfile
49
50CPPFLAGS += -I../common -I.
51CPPFLAGS += -I$(JAVA_ROOT)/include -I$(JAVA_ROOT)/include/solaris
52CPPFLAGS += -I../java/native
53CFLAGS += $(CCVERBOSE) -K PIC
54CFLAGS64 += $(CCVERBOSE) -K PIC
55LDLIBS += -lc -luutil -ldtrace -lproc
56
57LINTLIB =
58
59LFLAGS = -t -v
60
61ROOTDLIBDIR = $(ROOT)/usr/lib/dtrace_jni
62ROOTDLIBDIR64 = $(ROOT)/usr/lib/dtrace_jni/64
63
64ROOTDLIBS = $(DLIBSRCS:%=$(ROOTDLIBDIR)/%)
65
66.KEEP_STATE:
67
68all: $(DYNLIB)
69
70lint: lintcheck
71
72%.o: ../common/%.c
73	$(COMPILE.c) -o $@ $<
74	$(POST_PROCESS_O)
75
76$(ROOTDLIBDIR):
77	$(INS.dir)
78
79$(ROOTDLIBDIR64): $(ROOTDLIBDIR)
80	$(INS.dir)
81
82$(ROOTDLIBDIR)/%.o: %.o
83	$(INS.file)
84
85$(ROOTDLIBDIR64)/%.o: %.o
86	$(INS.file)
87
88$(ROOTDLIBS): $(ROOTDLIBDIR)
89
90$(ROOTDOBJS): $(ROOTDLIBDIR)
91
92$(ROOTDOBJS64): $(ROOTDLIBDIR64)
93
94include ../../Makefile.targ
95