move 32-bit libs to lib/i386 subdirs & 64-bit libs to lib/
[unleashed.git] / usr / src / cmd / mdb / intel / amd64 / kmdb / Makefile
blob2f46217cd38257e1d907d139436e0bae81a4506d
2 # CDDL HEADER START
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.
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.
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]
19 # CDDL HEADER END
22 # Copyright 2009 Sun Microsystems, Inc. All rights reserved.
23 # Use is subject to license terms.
27 # Build and link kmdb
29 all: $(PROG) kmdb_modlinktest.o
31 %.o: ../../kmdb/%.c
32 $(COMPILE.c) $<
33 $(CTFCONVERT_O)
35 %.o: ../../mdb/%.c
36 $(COMPILE.c) $<
37 $(CTFCONVERT_O)
39 %.o: $(SRC)/common/dis/i386/%.c
40 $(COMPILE.c) $<
41 $(CTFCONVERT_O)
43 ROOT_MISC_DIR = $(ROOT)/kernel/misc
45 ROOTMISC = $(ROOT_MISC_DIR)/$(PROG)
47 include ../../../../Makefile.cmd
48 include ../../../../Makefile.cmd.64
50 include ../../Makefile.amd64
51 include ../../../Makefile.kmdb
53 STANDLIBS += $(ROOT)/usr/lib/libstanddisasm.so
54 STANDLIBS += $(ROOT)/usr/lib/libstandsaveargs.so
56 INCDIRS += $(SRCTOP)/arch/x86/kernel/include
57 INCDIRS += $(SRC)/common/dis/i386
59 CPPFLAGS += -DDIS_TEXT
61 install: all $(ROOTMISC)
63 kmdb_context_off.h: ../../kmdb/kmdb_context_off.in
64 $(OFFSETS_CREATE) <../../kmdb/kmdb_context_off.in >$@
67 # Installation targets
70 $(ROOT_MISC_DIR):
71 -$(INS.dir)
73 $(ROOT_MISC_DIR)/%: % $(ROOT_MISC_DIR)
74 $(INS.file)