Makefile revision 7c478bd95313f5f23a4c958a745db2134aa03244
957N/A#
764N/A# CDDL HEADER START
764N/A#
919N/A# The contents of this file are subject to the terms of the
919N/A# Common Development and Distribution License, Version 1.0 only
919N/A# (the "License"). You may not use this file except in compliance
919N/A# with the License.
919N/A#
764N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
919N/A# or http://www.opensolaris.org/os/licensing.
919N/A# See the License for the specific language governing permissions
919N/A# and limitations under the License.
764N/A#
919N/A# When distributing Covered Code, include this CDDL HEADER in each
919N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
919N/A# If applicable, add the following below this CDDL HEADER, with the
919N/A# fields enclosed by brackets "[]" replaced with your own identifying
919N/A# information: Portions Copyright [yyyy] [name of copyright owner]
919N/A#
919N/A# CDDL HEADER END
764N/A#
764N/A#
764N/A# Copyright 2004 Sun Microsystems, Inc. All rights reserved.
764N/A# Use is subject to license terms.
764N/A#
764N/A# ident "%Z%%M% %I% %E% SMI"
764N/A#
957N/A# This makefile drives the production of the ibtl kernel module.
764N/A#
764N/A# sparc architecture dependent
764N/A#
764N/A
764N/A#
764N/A# Path to the base of the uts directory tree (usually /usr/src/uts).
764N/A#
764N/AUTSBASE = ../..
957N/A
957N/A#
764N/A# Define the module and object file sets.
#
MODULE = ibtl
OBJECTS = $(IBTL_OBJS:%=$(OBJS_DIR)/%)
LINTS = $(IBTL_OBJS:%.o=$(LINTS_DIR)/%.ln)
ROOTMODULE = $(ROOT_MISC_DIR)/$(MODULE)
WARLOCK_OBJS = $(IBTL_OBJS:%.o=%.ll)
WARLOCK_OK = $(MODULE).ok
#
# Include common rules.
#
include $(UTSBASE)/sparc/Makefile.sparc
#
# Define targets
#
ALL_TARGET = $(BINARY)
LINT_TARGET = $(MODULE).lint
INSTALL_TARGET = $(BINARY) $(ROOTMODULE)
#
# Overrides.
#
ALL_BUILDS = $(ALL_BUILDSONLY64)
DEF_BUILDS = $(DEF_BUILDSONLY64)
#
# lint pass one enforcement
#
CFLAGS += $(CCVERBOSE)
#
# Default build targets.
#
.KEEP_STATE:
def: $(DEF_DEPS)
all: $(ALL_DEPS)
clean: $(CLEAN_DEPS); \
$(RM) $(WARLOCK_OBJS) $(WARLOCK_OK)
clobber: $(CLOBBER_DEPS); \
$(RM) $(WARLOCK_OBJS) $(WARLOCK_OK)
lint: $(LINT_DEPS)
modlintlib: $(MODLINTLIB_DEPS) lint32
clean.lint: $(CLEAN_LINT_DEPS)
install: $(INSTALL_DEPS)
#
# Include common targets.
#
include $(UTSBASE)/sparc/Makefile.targ
#
# Defines for local commands.
#
WARLOCK = warlock
WLCC = wlcc
TOUCH = touch
SCCS = sccs
TEST = test
warlock: $(MODULE).ok
%.wlcmd:
$(TEST) -f $@ || $(SCCS) get $@
$(MODULE).ok: $(WARLOCK_OBJS) warlock_ddi.files ibtl.wlcmd
$(WARLOCK) -c ./ibtl.wlcmd $(WARLOCK_OBJS) -l ../warlock/ddi_dki_impl.ll
$(TOUCH) $@
%.ll: $(UTSBASE)/common/io/ib/ibtl/%.c
$(WLCC) $(CPPFLAGS) -DDEBUG -o $@ $<
warlock_ddi.files:
@cd ../warlock; pwd; $(MAKE) warlock