xref: /titanic_44/usr/src/uts/intel/hxge/Makefile (revision fe930412c257f961ae67039de3b164b83717976a)
13dec9fcdSqs148142#
23dec9fcdSqs148142# CDDL HEADER START
33dec9fcdSqs148142#
43dec9fcdSqs148142# The contents of this file are subject to the terms of the
53dec9fcdSqs148142# Common Development and Distribution License (the "License").
63dec9fcdSqs148142# You may not use this file except in compliance with the License.
73dec9fcdSqs148142#
83dec9fcdSqs148142# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
93dec9fcdSqs148142# or http://www.opensolaris.org/os/licensing.
103dec9fcdSqs148142# See the License for the specific language governing permissions
113dec9fcdSqs148142# and limitations under the License.
123dec9fcdSqs148142#
133dec9fcdSqs148142# When distributing Covered Code, include this CDDL HEADER in each
143dec9fcdSqs148142# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
153dec9fcdSqs148142# If applicable, add the following below this CDDL HEADER, with the
163dec9fcdSqs148142# fields enclosed by brackets "[]" replaced with your own identifying
173dec9fcdSqs148142# information: Portions Copyright [yyyy] [name of copyright owner]
183dec9fcdSqs148142#
193dec9fcdSqs148142# CDDL HEADER END
203dec9fcdSqs148142#
213dec9fcdSqs148142# uts/intel/hxge/Makefile
223dec9fcdSqs148142#
233dec9fcdSqs148142# Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
243dec9fcdSqs148142# Use is subject to license terms.
253dec9fcdSqs148142#
263dec9fcdSqs148142#
273dec9fcdSqs148142# ident	"%Z%%M%	%I%	%E% SMI"
283dec9fcdSqs148142#
293dec9fcdSqs148142#	This makefile drives the production of the Sun
303dec9fcdSqs148142#	10G hxge Ethernet leaf driver kernel module.
313dec9fcdSqs148142#
323dec9fcdSqs148142#
333dec9fcdSqs148142#	Path to the base of the uts directory tree (usually /usr/src/uts).
343dec9fcdSqs148142#
353dec9fcdSqs148142UTSBASE	= ../..
363dec9fcdSqs148142
373dec9fcdSqs148142#
383dec9fcdSqs148142#	Define the module and object file sets.
393dec9fcdSqs148142#
403dec9fcdSqs148142MODULE		= hxge
413dec9fcdSqs148142HXGE_OBJECTS =	$(HXGE_OBJS) $(HXGE_HPI_OBJS)
423dec9fcdSqs148142OBJECTS		=  $(HXGE_OBJECTS:%=$(OBJS_DIR)/%)
433dec9fcdSqs148142LINTS		= $(HXGE_OBJECTS:%.o=$(LINTS_DIR)/%.ln)
443dec9fcdSqs148142ROOTMODULE	= $(ROOT_DRV_DIR)/$(MODULE)
453dec9fcdSqs148142CONF_SRCDIR	= $(UTSBASE)/common/io/hxge
463dec9fcdSqs148142
473dec9fcdSqs148142#
483dec9fcdSqs148142#	Include common rules.
493dec9fcdSqs148142#
503dec9fcdSqs148142include $(UTSBASE)/intel/Makefile.intel
513dec9fcdSqs148142
523dec9fcdSqs148142#
533dec9fcdSqs148142#	Override defaults to build a unique, local modstubs.o.
543dec9fcdSqs148142#
553dec9fcdSqs148142MODSTUBS_DIR	= $(OBJS_DIR)
563dec9fcdSqs148142
573dec9fcdSqs148142CLEANFILES	+= $(MODSTUBS_O)
583dec9fcdSqs148142
593dec9fcdSqs148142#
603dec9fcdSqs148142#	Define targets
613dec9fcdSqs148142#
623dec9fcdSqs148142ALL_TARGET	= $(BINARY)
633dec9fcdSqs148142LINT_TARGET	= $(MODULE).lint
643dec9fcdSqs148142INSTALL_TARGET	= $(BINARY) $(ROOTMODULE) $(ROOT_CONFFILE)
653dec9fcdSqs148142
663dec9fcdSqs148142#
673dec9fcdSqs148142#
683dec9fcdSqs148142# Turn on doubleword alignment for 64 bit registers
693dec9fcdSqs148142#
703dec9fcdSqs148142CFLAGS	+= -dalign
713dec9fcdSqs148142#
723dec9fcdSqs148142# Include hxge specific header files
733dec9fcdSqs148142#
743dec9fcdSqs148142INC_PATH	+= -I$(UTSBASE)/common
753dec9fcdSqs148142INC_PATH	+= -I$(UTSBASE)/common/io/hxge
763dec9fcdSqs148142#
773dec9fcdSqs148142#
783dec9fcdSqs148142# lint pass one enforcement
793dec9fcdSqs148142#
803dec9fcdSqs148142CFLAGS += -DSOLARIS
813dec9fcdSqs148142#
823dec9fcdSqs148142# Debug flags
833dec9fcdSqs148142#
843dec9fcdSqs148142# CFLAGS += -DHXGE_DEBUG -DHPI_DEBUG
853dec9fcdSqs148142#
863dec9fcdSqs148142LINTFLAGS += -DSOLARIS
873dec9fcdSqs148142#
883dec9fcdSqs148142# STREAMS, DDI API limitations and other ON header file definitions such as ethernet.h
893dec9fcdSqs148142# force us to turn off these lint checks.
903dec9fcdSqs148142#
913dec9fcdSqs148142LINTTAGS	+= -erroff=E_BAD_PTR_CAST_ALIGN
923dec9fcdSqs148142LINTTAGS	+= -erroff=E_PTRDIFF_OVERFLOW
933dec9fcdSqs148142LINTTAGS	+= -erroff=E_FALSE_LOGICAL_EXPR
943dec9fcdSqs148142#
953dec9fcdSqs148142#	Driver depends on mac & IP
963dec9fcdSqs148142#
973dec9fcdSqs148142LDFLAGS		+= -dy -N misc/mac -N drv/ip
983dec9fcdSqs148142
993dec9fcdSqs148142#
1003dec9fcdSqs148142#	Default build targets.
1013dec9fcdSqs148142#
1023dec9fcdSqs148142.KEEP_STATE:
1033dec9fcdSqs148142
1043dec9fcdSqs148142def:		$(DEF_DEPS)
1053dec9fcdSqs148142
1063dec9fcdSqs148142all:		$(ALL_DEPS)
1073dec9fcdSqs148142
1083dec9fcdSqs148142clean:		$(CLEAN_DEPS)
1093dec9fcdSqs148142
1103dec9fcdSqs148142clobber:	$(CLOBBER_DEPS)
1113dec9fcdSqs148142
1123dec9fcdSqs148142lint:		$(LINT_DEPS)
1133dec9fcdSqs148142
114*fe930412Sqs148142modlintlib:	$(MODLINTLIB_DEPS)
1153dec9fcdSqs148142
1163dec9fcdSqs148142clean.lint:	$(CLEAN_LINT_DEPS)
1173dec9fcdSqs148142
1183dec9fcdSqs148142install:	$(INSTALL_DEPS)
1193dec9fcdSqs148142
1203dec9fcdSqs148142#
1213dec9fcdSqs148142#	Include common targets.
1223dec9fcdSqs148142#
1233dec9fcdSqs148142include $(UTSBASE)/intel/Makefile.targ
124