xref: /titanic_51/usr/src/uts/sun4u/i2c_svc/Makefile (revision 791a814c934fcd4deb13b26c1f116ff283272a0d)
1#
2#ident	"%Z%%M%	%I%	%E% SMI"
3#
4# Copyright 2004 Sun Microsystems, Inc.  All rights reserved.
5# Use is subject to license terms.
6
7#	This makefile drives the production of the i2c_svc misc module.
8#
9#	Path to the base of the uts directory tree (usually /usr/src/uts).
10
11UTSBASE	= ../..
12
13#
14#	Define the module and object file sets.
15#
16MODULE		= i2c_svc
17OBJECTS		= $(I2C_SVC_OBJS:%=$(OBJS_DIR)/%)
18LINTS		= $(I2C_SVC_OBJS:%.o=$(LINTS_DIR)/%.ln)
19ROOTMODULE	= $(ROOT_PSM_MISC_DIR)/$(MODULE)
20
21#
22#	Include common rules.
23#
24include $(UTSBASE)/sun4u/Makefile.sun4u
25
26#
27# lint pass one enforcement
28#
29CFLAGS += $(CCVERBOSE)
30
31LDFLAGS += -dy
32
33#
34#	Define targets
35#
36ALL_TARGET	= $(BINARY)
37LINT_TARGET	= $(MODULE).lint
38INSTALL_TARGET	= $(BINARY) $(ROOTMODULE)
39
40.KEEP_STATE:
41
42def:		$(DEF_DEPS)
43
44all:		$(ALL_DEPS)
45
46clean:		$(CLEAN_DEPS)
47
48clobber:	$(CLOBBER_DEPS)
49
50lint:		$(LINT_DEPS)
51
52modlintlib:	$(MODLINTLIB_DEPS)
53
54clean.lint:	$(CLEAN_LINT_DEPS)
55
56install:	$(INSTALL_DEPS)
57
58#
59#	Include common targets.
60#
61include $(UTSBASE)/sun4u/Makefile.targ
62
63#
64#	Defines for local commands.
65#
66WLCC		= wlcc
67TOUCH		= touch
68WARLOCK		= warlock
69
70#
71#	Warlock targets
72#
73
74I2C_SVC_FILES = $(I2C_SVC_OBJS:%.o=%.ll)
75
76warlock: $(MODULE).ok
77
78%.ok:	$(I2C_SVC_FILES)
79	$(TOUCH) $@
80
81%.ll: $(UTSBASE)/sun4u/io/i2c/misc/%.c
82	$(WLCC) $(CFLAGS) $(CPPFLAGS) -DDEBUG -o $@ $<
83