xref: /illumos-gate/usr/src/uts/intel/bnxe/Makefile (revision 20a7641f9918de8574b8b3b47dbe35c4bfc78df1)
1#
2# This file and its contents are supplied under the terms of the
3# Common Development and Distribution License ("CDDL"), version 1.0.
4# You may only use this file in accordance with the terms of version
5# 1.0 of the CDDL.
6#
7# A full copy of the text of the CDDL should have accompanied this
8# source.  A copy of the CDDL is also available via the Internet at
9# http://www.illumos.org/license/CDDL.
10#
11
12#
13# Copyright (c) 2019, Joyent, Inc.
14#
15
16#
17# uts/intel/bnxe/Makefile
18#
19#	This makefile drives the production of the bnxe
20#	driver kernel module.
21#
22#	intel architecture dependent
23#
24
25#
26#	Paths to the base of the uts directory trees
27#
28UTSBASE = ../..
29
30#
31#	Define the module and object file sets.
32#
33MODULE		= bnxe
34OBJECTS		= $(BNXE_OBJS:%=$(OBJS_DIR)/%)
35ROOTMODULE	= $(ROOT_DRV_DIR)/$(MODULE)
36SRCDIR		= $(UTSBASE)/common/io/bnxe
37CONF_SRCDIR	= $(SRCDIR)
38
39#
40#	Include common rules.
41#
42include $(UTSBASE)/intel/Makefile.intel
43
44#
45#	Define targets
46#
47ALL_TARGET	= $(BINARY) $(CONFMOD)
48INSTALL_TARGET	= $(BINARY) $(ROOTMODULE) $(ROOT_CONFFILE)
49
50#
51#	Driver-specific flags
52#	XXX inline bits were originally set to inline
53#
54CPPFLAGS	+= -DLM_RXPKT_NON_CONTIGUOUS \
55		   -DELINK_ENHANCEMENTS \
56		   -DELINK_57711E_SUPPORT \
57		   -DELINK_DEBUG \
58		   -D__inline= \
59		   -D_inline= \
60		   -D__BASENAME__=\"bnxe\" \
61		   -D__SunOS \
62		   -D__S11 \
63		   -DILLUMOS \
64		   -DLITTLE_ENDIAN \
65		   -DLITTLE_ENDIAN_HOST \
66		   -D__LITTLE_ENDIAN \
67		   -I$(SRCDIR)/577xx/include \
68		   -I$(SRCDIR)/577xx/drivers/common/ecore \
69		   -I$(SRCDIR)/577xx/drivers/common/include \
70		   -I$(SRCDIR)/577xx/drivers/common/include/l4 \
71		   -I$(SRCDIR)/577xx/drivers/common/include/l5 \
72		   -I$(SRCDIR)/577xx/drivers/common/lm/device \
73		   -I$(SRCDIR)/577xx/drivers/common/lm/fw \
74		   -I$(SRCDIR)/577xx/drivers/common/lm/include \
75		   -I$(SRCDIR)/577xx/drivers/common/lm/l4 \
76		   -I$(SRCDIR)/577xx/drivers/common/lm/l4/include \
77		   -I$(SRCDIR)/577xx/drivers/common/lm/l5 \
78		   -I$(SRCDIR)/577xx/drivers/common/lm/l5/include \
79		   -I$(SRCDIR)/577xx/hsi/hw/include \
80		   -I$(SRCDIR)/577xx/hsi/mcp \
81		   -I$(SRCDIR)
82
83LDFLAGS		+= -Ndrv/ip -Nmisc/mac
84CERRWARN	+= -_gcc=-Wno-switch
85CERRWARN	+= $(CNOWARN_UNINIT)
86CERRWARN	+= -_gcc=-Wno-parentheses
87CERRWARN	+= -_gcc=-Wno-unused-function
88CERRWARN	+= -_gcc=-Wno-unused-value
89CERRWARN	+= -_gcc=-Wno-unused-variable
90CERRWARN	+= -_gcc=-Wno-unused-but-set-variable
91CERRWARN	+= -_cc=-erroff=E_STATEMENT_NOT_REACHED
92CERRWARN	+= -_cc=-erroff=E_ARGUEMENT_MISMATCH
93CERRWARN	+= -_cc=-erroff=E_INTEGER_OVERFLOW_DETECTED
94CERRWARN	+= -_cc=-erroff=E_CONST_PROMOTED_UNSIGNED_LL
95CERRWARN	+= -_cc=-erroff=E_ENUM_VAL_OVERFLOWS_INT_MAX
96
97# a whole mess
98SMATCH=off
99
100
101#
102#	Default build targets.
103#
104.KEEP_STATE:
105
106def:		$(DEF_DEPS)
107
108all:		$(ALL_DEPS)
109
110clean:		$(CLEAN_DEPS)
111
112clobber:	$(CLOBBER_DEPS)
113
114install:	$(INSTALL_DEPS)
115
116#
117#	Include common targets.
118#
119include $(UTSBASE)/intel/Makefile.targ
120