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]
23 # Copyright 2008 Sun Microsystems, Inc. All rights reserved.
24 # Use is subject to license terms.
28 # This makefile drives the production of the aac driver kernel module.
30 # intel implementation architecture dependent
34 # Path to the base of the uts directory tree (usually /usr/src/uts).
39 # Define the module and object file sets.
42 OBJECTS
= $(AAC_OBJS
:%=$(OBJS_DIR
)/%)
43 LINTS
= $(AAC_OBJS
:%.o
=$(LINTS_DIR
)/%.ln
)
44 ROOTMODULE
= $(ROOT_DRV_DIR
)/$(MODULE
)
45 CONF_SRCDIR
= $(UTSBASE
)/common
/io
/aac
46 WARLOCK_OUT
= $(AAC_OBJS
:%.o
=%.ll
)
47 WARLOCK_OK
= $(MODULE
).ok
48 WLCMD_DIR
= $(UTSBASE
)/common
/io
/warlock
51 # Include common rules.
53 include $(UTSBASE
)/intel
/Makefile.intel
58 ALL_TARGET
= $(BINARY
) $(CONFMOD
)
59 LINT_TARGET
= $(MODULE
).lint
60 INSTALL_TARGET
= $(BINARY
) $(ROOTMODULE
) $(ROOT_CONFFILE
)
63 # Kernel Module Dependencies
65 LDFLAGS
+= -dy
-Nmisc
/scsi
71 CERRWARN
+= -_gcc
=-Wno-uninitialized
72 CERRWARN
+= -_gcc
=-Wno-parentheses
73 CERRWARN
+= -_gcc
=-Wno-unused-value
74 CERRWARN
+= -_gcc
=-Wno-unused-label
75 CERRWARN
+= -_gcc
=-Wno-switch
78 # Default build targets.
88 clobber: $(CLOBBER_DEPS
)
92 modlintlib
: $(MODLINTLIB_DEPS
)
94 clean.lint
: $(CLEAN_LINT_DEPS
)
96 install: $(INSTALL_DEPS
)
99 # Include common targets.
101 include $(UTSBASE
)/intel
/Makefile.targ
104 # Defines for local commands.
114 SCSI_FILES
= $(SCSI_OBJS
:%.o
= -l
$(UTSBASE
)/intel
/scsi
/%.ll
)
117 cd
$(WLCMD_DIR
); $(TEST
) -f
$@ ||
$(SCCS
) get $@
119 warlock
: $(WARLOCK_OK
)
121 $(WARLOCK_OK
): $(WARLOCK_OUT
) warlock_ddi.files scsi.files aac.wlcmd
122 $(WARLOCK
) -c
$(WLCMD_DIR
)/aac.wlcmd
$(WARLOCK_OUT
) \
124 $(UTSBASE
)/intel
/warlock
/scsi.ll \
125 -l
$(UTSBASE
)/intel
/warlock
/ddi_dki_impl.ll
128 %.ll
: $(UTSBASE
)/common
/io
/aac
/%.c
129 $(WLCC
) $(CPPFLAGS
) -DDEBUG
-o
$@
$<
132 @cd
$(UTSBASE
)/intel
/warlock
; pwd
; $(MAKE
) warlock
135 @cd
$(UTSBASE
)/intel
/scsi
; pwd
; $(MAKE
) warlock