Makefile revision 942c5e3c2dd127463517e5cc1694ee94ca45e021
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# CDDL HEADER START
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# The contents of this file are subject to the terms of the
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Common Development and Distribution License (the "License").
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# You may not use this file except in compliance with the License.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# or http://www.opensolaris.org/os/licensing.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# See the License for the specific language governing permissions
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# and limitations under the License.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# When distributing Covered Code, include this CDDL HEADER in each
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# If applicable, add the following below this CDDL HEADER, with the
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# fields enclosed by brackets "[]" replaced with your own identifying
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# information: Portions Copyright [yyyy] [name of copyright owner]
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# CDDL HEADER END
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Use is subject to license terms.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# ident "%Z%%M% %I% %E% SMI"
15131f635944423d12704f2e6e51799511ac51ccvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# This makefile drives the production of the aac driver kernel module.
15131f635944423d12704f2e6e51799511ac51ccvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# intel implementation architecture dependent
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Path to the base of the uts directory tree (usually /usr/src/uts).
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncUTSBASE = ../..
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Define the module and object file sets.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncMODULE = aac
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncOBJECTS = $(AAC_OBJS:%=$(OBJS_DIR)/%)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncLINTS = $(AAC_OBJS:%.o=$(LINTS_DIR)/%.ln)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncROOTMODULE = $(ROOT_DRV_DIR)/$(MODULE)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncCONF_SRCDIR = $(UTSBASE)/common/io/aac
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncWARLOCK_OUT = $(AAC_OBJS:%.o=%.ll)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncWARLOCK_OK = $(MODULE).ok
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncWLCMD_DIR = $(UTSBASE)/common/io/warlock
15131f635944423d12704f2e6e51799511ac51ccvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Include common rules.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
15131f635944423d12704f2e6e51799511ac51ccvboxsyncinclude $(UTSBASE)/intel/Makefile.intel
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Define targets
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncALL_TARGET = $(BINARY) $(CONFMOD)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncLINT_TARGET = $(MODULE).lint
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncINSTALL_TARGET = $(BINARY) $(ROOTMODULE) $(ROOT_CONFFILE)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Kernel Module Dependencies
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncLDFLAGS += -dy -Nmisc/scsi
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# For now, disable these lint checks; maintainers should endeavor
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# to investigate and remove these for maximum lint coverage.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Please do not carry these forward to new Makefiles.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncLINTTAGS += -erroff=E_BAD_PTR_CAST_ALIGN
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncLINTTAGS += -erroff=E_PTRDIFF_OVERFLOW
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Overrides
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Default build targets.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync.KEEP_STATE:
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncdef: $(DEF_DEPS)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncall: $(ALL_DEPS)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncclean: $(CLEAN_DEPS)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncclobber: $(CLOBBER_DEPS)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsynclint: $(LINT_DEPS)
2fc831009973ba4f02b68bfccfd69fa85d8f522bvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncmodlintlib: $(MODLINTLIB_DEPS)
2fc831009973ba4f02b68bfccfd69fa85d8f522bvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncclean.lint: $(CLEAN_LINT_DEPS)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncinstall: $(INSTALL_DEPS)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Include common targets.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncinclude $(UTSBASE)/intel/Makefile.targ
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# Defines for local commands.
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncWARLOCK = warlock
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncWLCC = wlcc
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncTOUCH = touch
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncTEST = test
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync# lock_lint rules
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync#
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncSCSI_FILES = $(SCSI_OBJS:%.o= -l $(UTSBASE)/intel/scsi/%.ll)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync%.wlcmd:
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync cd $(WLCMD_DIR); $(TEST) -f $@ || $(SCCS) get $@
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncwarlock: $(WARLOCK_OK)
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync$(WARLOCK_OK): $(WARLOCK_OUT) warlock_ddi.files scsi.files aac.wlcmd
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync $(WARLOCK) -c $(WLCMD_DIR)/aac.wlcmd $(WARLOCK_OUT) \
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync $(SCSI_FILES) \
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync $(UTSBASE)/intel/warlock/scsi.ll \
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync -l $(UTSBASE)/intel/warlock/ddi_dki_impl.ll
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync $(TOUCH) $@
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync%.ll: $(UTSBASE)/common/io/aac/%.c
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync $(WLCC) $(CPPFLAGS) -DDEBUG -o $@ $<
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncwarlock_ddi.files:
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync @cd $(UTSBASE)/intel/warlock; pwd; $(MAKE) warlock
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsyncscsi.files:
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync @cd $(UTSBASE)/intel/scsi; pwd; $(MAKE) warlock
14ea49401f3c8c61422aefbda43809e275f60c6cvboxsync