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]
22 # uts/intel/wusb_ca/Makefile
23 # Copyright 2009 Sun Microsystems, Inc. All rights reserved.
24 # Use is subject to license terms.
27 # This makefile drives the production of the wusb_ca driver kernel module.
31 # Path to the base of the uts directory tree (usually /usr/src/uts).
36 # Define the module and object file sets.
39 OBJECTS
= $(WUSB_CA_OBJS
:%=$(OBJS_DIR
)/%)
40 LINTS
= $(WUSB_CA_OBJS
:%.o
=$(LINTS_DIR
)/%.ln
)
41 ROOTMODULE
= $(ROOT_DRV_DIR
)/$(MODULE
)
42 WARLOCK_OUT
= $(WUSB_CA_OBJS
:%.o
=%.ll
)
43 WARLOCK_OK
= $(MODULE
).ok
44 WLCMD_DIR
= $(UTSBASE
)/common
/io
/warlock
47 # Include common rules.
49 include $(UTSBASE
)/intel
/Makefile.intel
54 ALL_TARGET
= $(BINARY
)
55 LINT_TARGET
= $(MODULE
).lint
56 INSTALL_TARGET
= $(BINARY
) $(ROOTMODULE
)
59 # Override defaults to build a unique, local modstubs.o.
61 MODSTUBS_DIR
= $(OBJS_DIR
)
62 CLEANFILES
+= $(MODSTUBS_O
)
65 # depends on misc/usba
67 LDFLAGS
+= -dy
-Nmisc
/usba
70 # For now, disable these lint checks; maintainers should endeavor
71 # to investigate and remove these for maximum lint coverage.
72 # Please do not carry these forward to new Makefiles.
74 LINTTAGS
+= -erroff
=E_SUPPRESSION_DIRECTIVE_UNUSED
75 LINTTAGS
+= -erroff
=E_BAD_PTR_CAST_ALIGN
76 LINTTAGS
+= -erroff
=E_ASSIGN_NARROW_CONV
79 # Default build targets.
88 $(RM
) $(WARLOCK_OUT
) $(WARLOCK_OK
)
90 clobber: $(CLOBBER_DEPS
)
91 $(RM
) $(WARLOCK_OUT
) $(WARLOCK_OK
)
95 modlintlib
: $(MODLINTLIB_DEPS
)
97 clean.lint
: $(CLEAN_LINT_DEPS
)
99 install: $(INSTALL_DEPS
)
102 # Include common targets.
104 include $(UTSBASE
)/intel
/Makefile.targ
107 # Defines for local commands.
118 USBA_FILES
= $(USBA_OBJS
:%.o
= -l ..
/usba
/%.ll
)
119 OHCI_FILES
= $(OHCI_OBJS
:%.o
=..
/ohci
/%.ll
)
120 UHCI_FILES
= $(UHCI_OBJS
:%.o
=..
/uhci
/%.ll
)
121 EHCI_FILES
= $(EHCI_OBJS
:%.o
=..
/ehci
/%.ll
)
123 warlock
: $(WARLOCK_OK
) warlock_with_usba
126 cd
$(WLCMD_DIR
); $(TEST
) -f
$@ ||
$(SCCS
) get $@
128 $(WARLOCK_OK
): $(WARLOCK_OUT
) wusb_ca.wlcmd warlock_ddi.files
129 $(WARLOCK
) -c
$(WLCMD_DIR
)/wusb_ca.wlcmd
$(WARLOCK_OUT
) \
130 -l ..
/warlock
/ddi_dki_impl.ll
133 %.ll
: $(UTSBASE
)/common
/io
/usb
/clients
/wusb_ca
/%.c \
134 $(UTSBASE
)/common
/sys
/usb
/clients
/wusb_ca
/wusb_ca_priv.h
135 $(WLCC
) $(CPPFLAGS
) -DDEBUG
-o
$@
$<
137 warlock_with_usba
: wusb_ca.wlcmd
$(WARLOCK_OUT
) usba_files \
139 $(WARLOCK
) -c
$(WLCMD_DIR
)/wusb_ca_with_usba.wlcmd \
140 $(USBA_FILES
) $(WARLOCK_OUT
) \
141 -l ..
/warlock
/ddi_dki_impl.ll
144 @cd ..
/usba
;pwd
; $(MAKE
) warlock
147 @cd ..
/ohci
;pwd
; $(MAKE
) warlock
150 @cd ..
/uhci
;pwd
; $(MAKE
) warlock
153 @cd ..
/ehci
;pwd
; $(MAKE
) warlock
156 cd ..
/warlock
; pwd
; $(MAKE
) warlock