Makefile revision 7c478bd95313f5f23a4c958a745db2134aa03244
6f7660093e70d3a7c80738b681ac0f5c1b661c00Mark Andrews#
6f7660093e70d3a7c80738b681ac0f5c1b661c00Mark Andrews# CDDL HEADER START
1fdbadc594a49b423052ea342dac74ff1a36089dMark Andrews#
1fdbadc594a49b423052ea342dac74ff1a36089dMark Andrews# The contents of this file are subject to the terms of the
a1898260ad19d02e88ab76c1855d33c67add9defMark Andrews# Common Development and Distribution License, Version 1.0 only
a1898260ad19d02e88ab76c1855d33c67add9defMark Andrews# (the "License"). You may not use this file except in compliance
a1898260ad19d02e88ab76c1855d33c67add9defMark Andrews# with the License.
305b0eda33b16493355db1f1c86313a6f5fbfc3bDanny Mayer#
305b0eda33b16493355db1f1c86313a6f5fbfc3bDanny Mayer# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
305b0eda33b16493355db1f1c86313a6f5fbfc3bDanny Mayer# or http://www.opensolaris.org/os/licensing.
305b0eda33b16493355db1f1c86313a6f5fbfc3bDanny Mayer# See the License for the specific language governing permissions
c0b6c1a5ab50722793cb99b0d8a1e9e910c146a5Andreas Gustafsson# and limitations under the License.
d16b4e8ba885a45933dc6a46f340b76811d60c74Andreas Gustafsson#
d16b4e8ba885a45933dc6a46f340b76811d60c74Andreas Gustafsson# When distributing Covered Code, include this CDDL HEADER in each
de9833be77ef92c17b35c02d138a0ad8df34dd91Mark Andrews# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
de9833be77ef92c17b35c02d138a0ad8df34dd91Mark Andrews# If applicable, add the following below this CDDL HEADER, with the
de9833be77ef92c17b35c02d138a0ad8df34dd91Mark Andrews# fields enclosed by brackets "[]" replaced with your own identifying
c0b6c1a5ab50722793cb99b0d8a1e9e910c146a5Andreas Gustafsson# information: Portions Copyright [yyyy] [name of copyright owner]
c0b6c1a5ab50722793cb99b0d8a1e9e910c146a5Andreas Gustafsson#
c0b6c1a5ab50722793cb99b0d8a1e9e910c146a5Andreas Gustafsson# CDDL HEADER END
4e400cb7a2edd25af98ebc25fcbb5b36ca08f9a0Mark Andrews#
c0b6c1a5ab50722793cb99b0d8a1e9e910c146a5Andreas Gustafsson#
c0b6c1a5ab50722793cb99b0d8a1e9e910c146a5Andreas Gustafsson# uts/sparc/ehci/Makefile
c0b6c1a5ab50722793cb99b0d8a1e9e910c146a5Andreas Gustafsson#
c0b6c1a5ab50722793cb99b0d8a1e9e910c146a5Andreas Gustafsson# Copyright 2004 Sun Microsystems, Inc. All rights reserved.
c0b6c1a5ab50722793cb99b0d8a1e9e910c146a5Andreas Gustafsson# Use is subject to license terms.
c0b6c1a5ab50722793cb99b0d8a1e9e910c146a5Andreas Gustafsson#
c0b6c1a5ab50722793cb99b0d8a1e9e910c146a5Andreas Gustafsson#ident "%Z%%M% %I% %E% SMI"
c0b6c1a5ab50722793cb99b0d8a1e9e910c146a5Andreas Gustafsson#
c0b6c1a5ab50722793cb99b0d8a1e9e910c146a5Andreas Gustafsson# This makefile drives the production of the ehci driver kernel module.
ec5a06ccf7b15f07d20fd872c3dc1ab8f82f2ceaMark Andrews#
907ec2c618d08d8322b04729779b24bd778d49e7Mark Andrews# sparc implementation architecture dependent
907ec2c618d08d8322b04729779b24bd778d49e7Mark Andrews#
907ec2c618d08d8322b04729779b24bd778d49e7Mark Andrews
23a020bc1312fc35e7c4ea36df846c550cb13634Andreas Gustafsson#
0a532842050020a1b0577c65f91f38bd022daa78Andreas Gustafsson# Path to the base of the uts directory tree (usually /usr/src/uts).
0a532842050020a1b0577c65f91f38bd022daa78Andreas Gustafsson#
0a532842050020a1b0577c65f91f38bd022daa78Andreas GustafssonUTSBASE = ../..
0a532842050020a1b0577c65f91f38bd022daa78Andreas Gustafsson
23a020bc1312fc35e7c4ea36df846c550cb13634Andreas Gustafsson#
23a020bc1312fc35e7c4ea36df846c550cb13634Andreas Gustafsson# Define the module and object file sets.
23a020bc1312fc35e7c4ea36df846c550cb13634Andreas Gustafsson#
44c141f9471a6bb1fac0cba7880ba768ede2f0c8Brian WellingtonMODULE = ehci
44c141f9471a6bb1fac0cba7880ba768ede2f0c8Brian WellingtonOBJECTS = $(EHCI_OBJS:%=$(OBJS_DIR)/%)
ab3eaa20e9a7e56208408563c79b4f8ac01d5e84Andreas GustafssonLINTS = $(EHCI_OBJS:%.o=$(LINTS_DIR)/%.ln)
e1a153c3f095e217eea29958950fea36e54862ceAndreas GustafssonWARLOCK_OUT = $(EHCI_OBJS:%.o=%.ll)
e1a153c3f095e217eea29958950fea36e54862ceAndreas GustafssonWARLOCK_OK = $(MODULE).ok
7250c1a2616761395bdb9ae7cd1ba43f20d3edc4Andreas GustafssonROOTMODULE = $(ROOT_DRV_DIR)/$(MODULE)
7250c1a2616761395bdb9ae7cd1ba43f20d3edc4Andreas GustafssonCONF_SRCDIR = $(UTSBASE)/common/io/usb/hcd/ehci
7250c1a2616761395bdb9ae7cd1ba43f20d3edc4Andreas Gustafsson
ab3eaa20e9a7e56208408563c79b4f8ac01d5e84Andreas Gustafsson
c38b92000c0f1a95daaad5468777e165b8047de9Mark Andrews#
4d77dbcfa052c065a87d2d35b116f17b74bae573Andreas Gustafsson# Include common rules.
c38b92000c0f1a95daaad5468777e165b8047de9Mark Andrews#
c38b92000c0f1a95daaad5468777e165b8047de9Mark Andrewsinclude $(UTSBASE)/sparc/Makefile.sparc
c38b92000c0f1a95daaad5468777e165b8047de9Mark Andrews
a5b9c2b208b51b039c8f4006cddf3d37dd781561Brian Wellington#
22f0b13f28a7df3b348b18848d0ccd745ea88c3cAndreas Gustafsson# lint pass one enforcement
22f0b13f28a7df3b348b18848d0ccd745ea88c3cAndreas Gustafsson#
22f0b13f28a7df3b348b18848d0ccd745ea88c3cAndreas GustafssonCFLAGS += $(CCVERBOSE)
22f0b13f28a7df3b348b18848d0ccd745ea88c3cAndreas Gustafsson
ee3ab6063dd13b5947d3fbe88b9ce8f38d65df9dBrian Wellington#
9261ca5fc8a564968f34e108eb862157471ca50eAndreas Gustafsson# depends on misc/usba
ee3ab6063dd13b5947d3fbe88b9ce8f38d65df9dBrian Wellington#
d81622b537be1971530cfb459acdbbe7d82d883bBrian WellingtonLDFLAGS += -dy -Nmisc/usba
d81622b537be1971530cfb459acdbbe7d82d883bBrian Wellington
a5b9c2b208b51b039c8f4006cddf3d37dd781561Brian Wellington#
9261ca5fc8a564968f34e108eb862157471ca50eAndreas Gustafsson# Define targets
a5b9c2b208b51b039c8f4006cddf3d37dd781561Brian Wellington#
a5b9c2b208b51b039c8f4006cddf3d37dd781561Brian WellingtonALL_TARGET = $(BINARY) $(SRC_CONFFILE)
2da0b7dfbd02fab454b8ba60f1fdb7e2a5cbd2dbMark AndrewsLINT_TARGET = $(MODULE).lint
2da0b7dfbd02fab454b8ba60f1fdb7e2a5cbd2dbMark AndrewsINSTALL_TARGET = $(BINARY) $(ROOTMODULE) $(ROOT_CONFFILE)
2da0b7dfbd02fab454b8ba60f1fdb7e2a5cbd2dbMark Andrews
1cb6e8cbe41afade950837319e04da4ccf8649e0Brian Wellington.KEEP_STATE:
9261ca5fc8a564968f34e108eb862157471ca50eAndreas Gustafsson
1cb6e8cbe41afade950837319e04da4ccf8649e0Brian Wellingtonall: $(ALL_DEPS)
2033e305852d4b76772885ea73ebfb6776c1f820Mark Andrews
6443201354efa09f16ada26dab99e9b7f8271521Andreas Gustafssondef: $(DEF_DEPS)
6443201354efa09f16ada26dab99e9b7f8271521Andreas Gustafsson
6443201354efa09f16ada26dab99e9b7f8271521Andreas Gustafssonclean: $(CLEAN_DEPS); \
e980502db40155234b4e8d320b748b34dbaba3a2Brian Wellington $(RM) $(WARLOCK_OUT) $(WARLOCK_OK)
e980502db40155234b4e8d320b748b34dbaba3a2Brian Wellington
e980502db40155234b4e8d320b748b34dbaba3a2Brian Wellingtonclobber: $(CLOBBER_DEPS); \
e980502db40155234b4e8d320b748b34dbaba3a2Brian Wellington $(RM) $(WARLOCK_OUT) $(WARLOCK_OK)
ecd1addb86319bacc6c0bff2c68373619eebbffcMark Andrews
ecd1addb86319bacc6c0bff2c68373619eebbffcMark Andrewslint: $(LINT_DEPS)
0176adc7c58bb8bd60ec71eeae94dbfbbc4018a8Mark Andrews
0176adc7c58bb8bd60ec71eeae94dbfbbc4018a8Mark Andrewsmodlintlib: $(MODLINTLIB_DEPS)
ea20115e347264b9bc1c686d6dfc1b5af3a5516bAndreas Gustafsson
ea20115e347264b9bc1c686d6dfc1b5af3a5516bAndreas Gustafssonclean.lint: $(CLEAN_LINT_DEPS)
ea20115e347264b9bc1c686d6dfc1b5af3a5516bAndreas Gustafsson
bddfe77128b0f16af263ff149db40f0d885f43d0Mark Andrewsinstall: $(INSTALL_DEPS)
bddfe77128b0f16af263ff149db40f0d885f43d0Mark Andrews
aa0dc8d920a1f79626c3564408db9c5c9a5319a7Andreas Gustafsson#
aa0dc8d920a1f79626c3564408db9c5c9a5319a7Andreas Gustafsson# Include common targets.
aa0dc8d920a1f79626c3564408db9c5c9a5319a7Andreas Gustafsson#
aa0dc8d920a1f79626c3564408db9c5c9a5319a7Andreas Gustafssoninclude $(UTSBASE)/sparc/Makefile.targ
47d48791fc352fcdf9019200070221be41a8d77cMark Andrews
47d48791fc352fcdf9019200070221be41a8d77cMark Andrews#
35db8a8eda6a889675138eb125d366c8851f68a5Andreas Gustafsson# Defines for local commands.
0d5e7cd0afaee07302f8364aa454f09b4c63ea79Andreas Gustafsson#
0d5e7cd0afaee07302f8364aa454f09b4c63ea79Andreas GustafssonWARLOCK = warlock
5e88852b94830bf71e37dc700d568cb35e2e6f7eAndreas GustafssonWLCC = wlcc
5e88852b94830bf71e37dc700d568cb35e2e6f7eAndreas GustafssonTOUCH = touch
5e88852b94830bf71e37dc700d568cb35e2e6f7eAndreas GustafssonSCCS = sccs
5e88852b94830bf71e37dc700d568cb35e2e6f7eAndreas GustafssonTEST = test
22815444822da17fab82d4ab115da6e055ea1754Brian Wellington
5e88852b94830bf71e37dc700d568cb35e2e6f7eAndreas Gustafsson#
22815444822da17fab82d4ab115da6e055ea1754Brian Wellington# lock_lint rules
22815444822da17fab82d4ab115da6e055ea1754Brian Wellington#
35db8a8eda6a889675138eb125d366c8851f68a5Andreas GustafssonWARLOCK_OBJECTS = $(EHCI_OBJS:%.o=%.ll)
35db8a8eda6a889675138eb125d366c8851f68a5Andreas GustafssonUSBA_FILES = $(USBA_OBJS:%.o= -l ../usba/%.ll)
35db8a8eda6a889675138eb125d366c8851f68a5Andreas Gustafsson
c6de6524d777c90ae8011af8b10f5cac044081e5Mark Andrewswarlock: $(MODULE).ok $(WARLOCK_OBJECTS)
bd6504aa9aa16a912412fbe010046aaf4bf23621Brian Wellington
bd6504aa9aa16a912412fbe010046aaf4bf23621Brian Wellington%.wlcmd:
5e88852b94830bf71e37dc700d568cb35e2e6f7eAndreas Gustafsson $(TEST) -f $@ || $(SCCS) get $@
bd6504aa9aa16a912412fbe010046aaf4bf23621Brian Wellington
bd6504aa9aa16a912412fbe010046aaf4bf23621Brian Wellingtonehci.ok: $(WARLOCK_OBJECTS) ehci.wlcmd warlock_ddi.files usba.files
bd6504aa9aa16a912412fbe010046aaf4bf23621Brian Wellington $(WARLOCK) -c ehci.wlcmd $(WARLOCK_OBJECTS) \
bd6504aa9aa16a912412fbe010046aaf4bf23621Brian Wellington $(USBA_FILES) \
e9596e1fb3dfa560216776acdbfac3cf5ef97157Mark Andrews -l ../warlock/ddi_dki_impl.ll
e9596e1fb3dfa560216776acdbfac3cf5ef97157Mark Andrews $(TOUCH) $@
1e289d3cca5cdd01dda650fa6e4c1de1aa8b4196Andreas Gustafsson
c54210716ee55b55e22d8dad56fd696a641fc98dBob Halley%.ll: $(UTSBASE)/common/io/usb/hcd/ehci/%.c
c54210716ee55b55e22d8dad56fd696a641fc98dBob Halley $(WLCC) $(CPPFLAGS) -DDEBUG -o $@ $<
c54210716ee55b55e22d8dad56fd696a641fc98dBob Halley
c54210716ee55b55e22d8dad56fd696a641fc98dBob Halleywarlock_ddi.files:
3fcf6b956f47405750724bd84e1b2290b61c9186Brian Wellington @cd ../warlock; pwd; $(MAKE) warlock
82c65f4f62819340ef8198932d3eab8a308a4874Andreas Gustafsson
3fcf6b956f47405750724bd84e1b2290b61c9186Brian Wellingtonusba.files:
1e289d3cca5cdd01dda650fa6e4c1de1aa8b4196Andreas Gustafsson @cd ../usba; pwd; $(MAKE) warlock
1e289d3cca5cdd01dda650fa6e4c1de1aa8b4196Andreas Gustafsson