xref: /titanic_51/usr/src/uts/sparc/dada/Makefile (revision ccbf80fa3b6bf6b986dca9037e5ad9d6c9f9fa65)
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, Version 1.0 only
6# (the "License").  You may not use this file except in compliance
7# with the License.
8#
9# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10# or http://www.opensolaris.org/os/licensing.
11# See the License for the specific language governing permissions
12# and limitations under the License.
13#
14# When distributing Covered Code, include this CDDL HEADER in each
15# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16# If applicable, add the following below this CDDL HEADER, with the
17# fields enclosed by brackets "[]" replaced with your own identifying
18# information: Portions Copyright [yyyy] [name of copyright owner]
19#
20# CDDL HEADER END
21#
22#
23# uts/sparc/dada/Makefile
24#
25# Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
26# Use is subject to license terms.
27#
28
29#ident	"%Z%%M%	%I%	%E% SMI"
30
31#
32#	Path to the base of the uts directory tree (usually /usr/src/uts).
33#
34UTSBASE	= ../..
35
36#
37#	Define the module and object file sets.
38#
39MODULE		= dada
40OBJECTS		= $(DADA_OBJS:%=$(OBJS_DIR)/%)
41LINTS		= $(DADA_OBJS:%.o=$(LINTS_DIR)/%.ln)
42ROOTMODULE	= $(ROOT_MISC_DIR)/$(MODULE)
43WARLOCK_OUT     = $(DADA_OBJS:%.o=%.ll)
44WARLOCK_OK      = $(MODULE).ok
45
46#
47#	Include common rules.
48#
49include $(UTSBASE)/sparc/Makefile.sparc
50
51
52#
53#	Define targets
54#
55ALL_TARGET	= $(BINARY)
56LINT_TARGET	= $(MODULE).lint
57INSTALL_TARGET	= $(BINARY) $(ROOTMODULE)
58
59#
60#	Overrides.
61#
62CFLAGS		+= $(CCVERBOSE)
63
64#
65#	Default build targets.
66#
67.KEEP_STATE:
68
69all:		$(ALL_DEPS)
70
71def:		$(DEF_DEPS)
72
73clean:		$(CLEAN_DEPS)
74
75clean:		$(CLEAN_DEPS); \
76		$(RM) $(WARLOCK_OUT) $(WARLOCK_OK)
77
78clobber:	$(CLOBBER_DEPS); \
79		$(RM) $(WARLOCK_OUT) $(WARLOCK_OK)
80
81modlintlib:	$(MODLINTLIB_DEPS) lint64
82
83clean.lint:	$(CLEAN_LINT_DEPS)
84
85install:	$(INSTALL_DEPS)
86
87#
88#	Include common targets.
89#
90include $(UTSBASE)/sparc/Makefile.targ
91
92#
93#	Defines for local commands.
94#
95WLCC		= wlcc
96TOUCH		= touch
97
98#
99#	Warlock targets
100#
101WARLOCK_OBJECTS	= $(DADA_OBJS:%.o=%.ll)
102
103warlock: $(MODULE).ok $(WARLOCK_OBJECTS)
104
105%.ok: $(WARLOCK_OBJECTS)
106	$(TOUCH) $@
107
108%.ll: $(UTSBASE)/sun/io/dada/impl/%.c
109	$(WLCC) $(CPPFLAGS) -o $@ $<
110
111%.ll: $(UTSBASE)/sun/io/dada/conf/%.c
112	$(WLCC) $(CPPFLAGS) -o $@ $<
113