xref: /titanic_44/usr/src/uts/intel/hxge/Makefile (revision 7014882c6a3672fd0e5d60200af8643ae53c5928)
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#
23310da939SSurya Prakki# Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved.
243dec9fcdSqs148142#
253dec9fcdSqs148142#	This makefile drives the production of the Sun
263dec9fcdSqs148142#	10G hxge Ethernet leaf driver kernel module.
273dec9fcdSqs148142#
283dec9fcdSqs148142#
293dec9fcdSqs148142#	Path to the base of the uts directory tree (usually /usr/src/uts).
303dec9fcdSqs148142#
313dec9fcdSqs148142UTSBASE	= ../..
323dec9fcdSqs148142
333dec9fcdSqs148142#
343dec9fcdSqs148142#	Define the module and object file sets.
353dec9fcdSqs148142#
363dec9fcdSqs148142MODULE		= hxge
373dec9fcdSqs148142HXGE_OBJECTS =	$(HXGE_OBJS) $(HXGE_HPI_OBJS)
383dec9fcdSqs148142OBJECTS		=  $(HXGE_OBJECTS:%=$(OBJS_DIR)/%)
393dec9fcdSqs148142LINTS		= $(HXGE_OBJECTS:%.o=$(LINTS_DIR)/%.ln)
403dec9fcdSqs148142ROOTMODULE	= $(ROOT_DRV_DIR)/$(MODULE)
413dec9fcdSqs148142CONF_SRCDIR	= $(UTSBASE)/common/io/hxge
423dec9fcdSqs148142
433dec9fcdSqs148142#
443dec9fcdSqs148142#	Include common rules.
453dec9fcdSqs148142#
463dec9fcdSqs148142include $(UTSBASE)/intel/Makefile.intel
473dec9fcdSqs148142
483dec9fcdSqs148142#
493dec9fcdSqs148142#	Override defaults to build a unique, local modstubs.o.
503dec9fcdSqs148142#
513dec9fcdSqs148142MODSTUBS_DIR	= $(OBJS_DIR)
523dec9fcdSqs148142
533dec9fcdSqs148142CLEANFILES	+= $(MODSTUBS_O)
543dec9fcdSqs148142
553dec9fcdSqs148142#
563dec9fcdSqs148142#	Define targets
573dec9fcdSqs148142#
583dec9fcdSqs148142ALL_TARGET	= $(BINARY)
593dec9fcdSqs148142LINT_TARGET	= $(MODULE).lint
603dec9fcdSqs148142INSTALL_TARGET	= $(BINARY) $(ROOTMODULE) $(ROOT_CONFFILE)
613dec9fcdSqs148142
623dec9fcdSqs148142#
633dec9fcdSqs148142# Include hxge specific header files
643dec9fcdSqs148142#
653dec9fcdSqs148142INC_PATH	+= -I$(UTSBASE)/common/io/hxge
663dec9fcdSqs148142#
673dec9fcdSqs148142#
683dec9fcdSqs148142# lint pass one enforcement
693dec9fcdSqs148142#
703dec9fcdSqs148142CFLAGS += -DSOLARIS
713dec9fcdSqs148142#
723dec9fcdSqs148142# Debug flags
733dec9fcdSqs148142#
743dec9fcdSqs148142# CFLAGS += -DHXGE_DEBUG -DHPI_DEBUG
753dec9fcdSqs148142#
763dec9fcdSqs148142LINTFLAGS += -DSOLARIS
773dec9fcdSqs148142#
783dec9fcdSqs148142# STREAMS, DDI API limitations and other ON header file definitions such as ethernet.h
793dec9fcdSqs148142# force us to turn off these lint checks.
803dec9fcdSqs148142#
813dec9fcdSqs148142LINTTAGS	+= -erroff=E_BAD_PTR_CAST_ALIGN
823dec9fcdSqs148142LINTTAGS	+= -erroff=E_PTRDIFF_OVERFLOW
833dec9fcdSqs148142LINTTAGS	+= -erroff=E_FALSE_LOGICAL_EXPR
84*7014882cSRichard Lowe
85*7014882cSRichard LoweCERRWARN	+= -_gcc=-Wno-unused-label
86*7014882cSRichard LoweCERRWARN	+= -_gcc=-Wno-switch
87*7014882cSRichard LoweCERRWARN	+= -_gcc=-Wno-uninitialized
88*7014882cSRichard LoweCERRWARN	+= -_gcc=-Wno-parentheses
89*7014882cSRichard Lowe
903dec9fcdSqs148142#
913dec9fcdSqs148142#	Driver depends on mac & IP
923dec9fcdSqs148142#
933dec9fcdSqs148142LDFLAGS		+= -dy -N misc/mac -N drv/ip
943dec9fcdSqs148142
953dec9fcdSqs148142#
963dec9fcdSqs148142#	Default build targets.
973dec9fcdSqs148142#
983dec9fcdSqs148142.KEEP_STATE:
993dec9fcdSqs148142
1003dec9fcdSqs148142def:		$(DEF_DEPS)
1013dec9fcdSqs148142
1023dec9fcdSqs148142all:		$(ALL_DEPS)
1033dec9fcdSqs148142
1043dec9fcdSqs148142clean:		$(CLEAN_DEPS)
1053dec9fcdSqs148142
1063dec9fcdSqs148142clobber:	$(CLOBBER_DEPS)
1073dec9fcdSqs148142
1083dec9fcdSqs148142lint:		$(LINT_DEPS)
1093dec9fcdSqs148142
110fe930412Sqs148142modlintlib:	$(MODLINTLIB_DEPS)
1113dec9fcdSqs148142
1123dec9fcdSqs148142clean.lint:	$(CLEAN_LINT_DEPS)
1133dec9fcdSqs148142
1143dec9fcdSqs148142install:	$(INSTALL_DEPS)
1153dec9fcdSqs148142
1163dec9fcdSqs148142#
1173dec9fcdSqs148142#	Include common targets.
1183dec9fcdSqs148142#
1193dec9fcdSqs148142include $(UTSBASE)/intel/Makefile.targ
120