Makefile revision 89b43686db1fe9681d80a7cf5662730cb9378cae
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# CDDL HEADER START
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# The contents of this file are subject to the terms of the
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Common Development and Distribution License (the "License").
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# You may not use this file except in compliance with the License.
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# or http://www.opensolaris.org/os/licensing.
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# See the License for the specific language governing permissions
0662ed52e814f8f08ef0e09956413a792584eddffuankg# and limitations under the License.
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# When distributing Covered Code, include this CDDL HEADER in each
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# If applicable, add the following below this CDDL HEADER, with the
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# fields enclosed by brackets "[]" replaced with your own identifying
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# information: Portions Copyright [yyyy] [name of copyright owner]
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
70953fb44a7140fe206c3a5f011e24209c8c5c6abnicholes# CDDL HEADER END
70953fb44a7140fe206c3a5f011e24209c8c5c6abnicholes#
44f575c8cb19a7a5cd61664a7848be6bc197df02fuankg#
16b55a35cff91315d261d1baa776138af465c4e4fuankg# uts/sparc/ses/Makefile
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Use is subject to license terms.
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Copyright (c) 2011 Bayard G. Bell. All rights reserved.
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# This makefile drives the production of the ses driver kernel module.
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# sparc architecture dependent
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Path to the base of the uts directory tree (usually /usr/src/uts).
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesUTSBASE = ../..
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Define the module and object file sets.
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesMODULE = ses
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesOBJECTS = $(SES_OBJS:%=$(OBJS_DIR)/%)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesLINTS = $(SES_OBJS:%.o=$(LINTS_DIR)/%.ln)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesROOTMODULE = $(ROOT_DRV_DIR)/$(MODULE)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesCONF_SRCDIR = $(UTSBASE)/sun/io/scsi/targets
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesWARLOCK_OUT = $(SES_OBJS:%.o=%.ll)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesWARLOCK_OK = $(MODULE).ok
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesWLCMD_DIR = $(UTSBASE)/common/io/warlock
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Include common rules.
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesinclude $(UTSBASE)/sparc/Makefile.sparc
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Define targets
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
ac7985784d08a3655291f24f711812b4d8b1cbcffuankgALL_TARGET = $(BINARY) $(SRC_CONFILE)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesLINT_TARGET = $(MODULE).lint
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesINSTALL_TARGET = $(BINARY) $(ROOTMODULE) $(ROOT_CONFFILE)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesCLEANFILES += $(WARLOCK_TARGETS)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Define dependency on scsi
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesLDFLAGS += -dy -N misc/scsi
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# For now, disable these lint checks; maintainers should endeavor
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# to investigate and remove these for maximum lint coverage.
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Please do not carry these forward to new Makefiles.
ac7985784d08a3655291f24f711812b4d8b1cbcffuankg#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesLINTTAGS += -erroff=E_BAD_PTR_CAST_ALIGN
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesLINTTAGS += -erroff=E_ASSIGN_NARROW_CONV
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesLINTTAGS += -erroff=E_SUSPICIOUS_COMPARISON
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Default build targets.
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes.KEEP_STATE:
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesdef: $(DEF_DEPS)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesall: $(ALL_DEPS)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesclean: $(CLEAN_DEPS)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes $(RM) $(WARLOCK_OUT) $(WARLOCK_OK)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesclobber: $(CLOBBER_DEPS)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes $(RM) $(WARLOCK_OUT) $(WARLOCK_OK)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesmodlintlib: $(MODLINTLIB_DEPS) lint64
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
ac7985784d08a3655291f24f711812b4d8b1cbcffuankgclean.lint: $(CLEAN_LINT_DEPS)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesinstall: $(INSTALL_DEPS)
ac7985784d08a3655291f24f711812b4d8b1cbcffuankg
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Include common targets.
0a39e7683f6611d66c55712f50bb240428d832a1bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesinclude $(UTSBASE)/sparc/Makefile.targ
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Defines for local commands.
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesWARLOCK = warlock
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesWLCC = wlcc
ac7985784d08a3655291f24f711812b4d8b1cbcffuankgTOUCH = touch
0662ed52e814f8f08ef0e09956413a792584eddffuankgTEST = test
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
ac7985784d08a3655291f24f711812b4d8b1cbcffuankg#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# Warlock targets
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes#
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes# XXX FIX ME. this can be improved quite a bit
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesSES_FILES = $(MODULE).ll
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesSCSI_FILES = $(SCSI_OBJS:%.o=-l ../scsi/%.ll)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholesWARLOCK_TARGETS = $(WARLOCK_OK) warlock_with_esp.ok warlock_with_fas.ok
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes$(CLOSED_BUILD)WARLOCK_TARGETS += warlock_with_isp.ok warlock_with_glm.ok
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
0662ed52e814f8f08ef0e09956413a792584eddffuankgwarlock: $(WARLOCK_TARGETS)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes$(WARLOCK_OK): $(WLCMD_DIR)/$(MODULE).wlcmd $(SES_FILES)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @cd ../warlock; $(MAKE) warlock
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @cd ../scsi; $(MAKE) warlock
0662ed52e814f8f08ef0e09956413a792584eddffuankg $(WARLOCK) -c $(WLCMD_DIR)/$(MODULE).wlcmd $(SES_FILES) ../warlock/scsi.ll \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes -l ../warlock/ddi_dki_impl.ll \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes $(SCSI_FILES)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @ $(TOUCH) $@
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholeswarlock_with_esp.ok: $(WLCMD_DIR)/ses_with_esp.wlcmd $(SES_FILES)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @cd ../warlock; $(MAKE) warlock
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @cd ../scsi; $(MAKE) warlock
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @cd ../esp; $(MAKE) warlock;
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes $(WARLOCK) -c $(WLCMD_DIR)/ses_with_esp.wlcmd $(SES_FILES) ../esp/esp \
0662ed52e814f8f08ef0e09956413a792584eddffuankg ../warlock/scsi.ll \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes -l ../warlock/ddi_dki_impl.ll \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes $(SCSI_FILES)
ac7985784d08a3655291f24f711812b4d8b1cbcffuankg @ $(TOUCH) $@
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholeswarlock_with_fas.ok: $(WLCMD_DIR)/ses_with_fas.wlcmd $(SES_FILES)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @cd ../warlock; $(MAKE) warlock
ac7985784d08a3655291f24f711812b4d8b1cbcffuankg @cd ../scsi; $(MAKE) warlock
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @cd ../fas; $(MAKE) warlock;
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes $(WARLOCK) -c $(WLCMD_DIR)/ses_with_fas.wlcmd $(SES_FILES) \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes ../fas/fas ../fas/fas_callbacks \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes ../warlock/scsi.ll \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes -l ../warlock/ddi_dki_impl.ll \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes $(SCSI_FILES)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @ $(TOUCH) $@
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholeswarlock_with_isp.ok: $(WLCMD_DIR)/ses_with_isp.wlcmd $(SES_FILES)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @cd ../warlock; $(MAKE) warlock
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @cd ../scsi; $(MAKE) warlock
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @cd $(CLOSED)/uts/sparc/isp; $(MAKE) warlock;
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes $(WARLOCK) -c $(WLCMD_DIR)/ses_with_isp.wlcmd $(SES_FILES) \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes $(CLOSED)/uts/sparc/isp/isp \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes ../warlock/scsi.ll \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes -l ../warlock/ddi_dki_impl.ll \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes $(SCSI_FILES)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @ $(TOUCH) $@
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholeswarlock_with_glm.ok: $(WLCMD_DIR)/ses_with_glm.wlcmd $(SES_FILES)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @cd ../warlock; $(MAKE) warlock
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @cd ../scsi; $(MAKE) warlock
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @cd $(CLOSED)/uts/sparc/glm; $(MAKE) warlock;
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes $(WARLOCK) -c $(WLCMD_DIR)/ses_with_glm.wlcmd $(SES_FILES) \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes $(CLOSED)/uts/sparc/glm/glm \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes ../warlock/scsi.ll \
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes -l ../warlock/ddi_dki_impl.ll \
cf7ca2f9eaa6523fefcccba4287b91637391fb51fuankg $(SCSI_FILES)
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes @ $(TOUCH) $@
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes%.ll: $(UTSBASE)/common/io/scsi/targets/%.c
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes $(WLCC) $(CPPFLAGS) -o $@ $<
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes
3c937b528ca923d5b51e63def9f888af4a77bb40bnicholes