xref: /titanic_44/usr/src/uts/intel/getgen/Makefile (revision b94833c41622a122a28c4fb18d62acc216249672)
1*b94833c4SAndreas Jaekel#
2*b94833c4SAndreas Jaekel# CDDL HEADER START
3*b94833c4SAndreas Jaekel#
4*b94833c4SAndreas Jaekel# The contents of this file are subject to the terms of the
5*b94833c4SAndreas Jaekel# Common Development and Distribution License (the "License").
6*b94833c4SAndreas Jaekel# You may not use this file except in compliance with the License.
7*b94833c4SAndreas Jaekel#
8*b94833c4SAndreas Jaekel# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9*b94833c4SAndreas Jaekel# or http://www.opensolaris.org/os/licensing.
10*b94833c4SAndreas Jaekel# See the License for the specific language governing permissions
11*b94833c4SAndreas Jaekel# and limitations under the License.
12*b94833c4SAndreas Jaekel#
13*b94833c4SAndreas Jaekel# When distributing Covered Code, include this CDDL HEADER in each
14*b94833c4SAndreas Jaekel# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15*b94833c4SAndreas Jaekel# If applicable, add the following below this CDDL HEADER, with the
16*b94833c4SAndreas Jaekel# fields enclosed by brackets "[]" replaced with your own identifying
17*b94833c4SAndreas Jaekel# information: Portions Copyright [yyyy] [name of copyright owner]
18*b94833c4SAndreas Jaekel#
19*b94833c4SAndreas Jaekel# CDDL HEADER END
20*b94833c4SAndreas Jaekel#
21*b94833c4SAndreas Jaekel#
22*b94833c4SAndreas Jaekel# Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
23*b94833c4SAndreas Jaekel#
24*b94833c4SAndreas Jaekel#	This makefile drives the production of the zut file system
25*b94833c4SAndreas Jaekel#	kernel module.
26*b94833c4SAndreas Jaekel
27*b94833c4SAndreas Jaekel#
28*b94833c4SAndreas Jaekel#	Path to the base of the uts directory tree (usually /usr/src/uts).
29*b94833c4SAndreas Jaekel#
30*b94833c4SAndreas JaekelUTSBASE	= ../..
31*b94833c4SAndreas Jaekel
32*b94833c4SAndreas JaekelARCHDIR:sh = cd ..; basename `pwd`
33*b94833c4SAndreas Jaekel
34*b94833c4SAndreas Jaekel#
35*b94833c4SAndreas Jaekel#	Define the module and object file sets.
36*b94833c4SAndreas Jaekel#
37*b94833c4SAndreas JaekelMODULE		= getgen
38*b94833c4SAndreas JaekelOBJECTS		= $(GETGEN_OBJS:%=$(OBJS_DIR)/%)
39*b94833c4SAndreas JaekelLINTS		= $(GETGEN_OBJS:%.o=$(LINTS_DIR)/%.ln)
40*b94833c4SAndreas JaekelROOTMODULE	= $(ROOT_DRV_DIR)/$(MODULE)
41*b94833c4SAndreas JaekelCONF_SRCDIR	= $(UTSBASE)/common/fs/getgen
42*b94833c4SAndreas Jaekel
43*b94833c4SAndreas Jaekel#
44*b94833c4SAndreas Jaekel#	Include common rules.
45*b94833c4SAndreas Jaekel#
46*b94833c4SAndreas Jaekelinclude ../Makefile.$(ARCHDIR)
47*b94833c4SAndreas Jaekel
48*b94833c4SAndreas Jaekel#
49*b94833c4SAndreas Jaekel#	Define targets
50*b94833c4SAndreas Jaekel#
51*b94833c4SAndreas JaekelALL_TARGET	= $(BINARY) $(SRC_CONFILE)
52*b94833c4SAndreas JaekelLINT_TARGET	= $(MODULE).lint
53*b94833c4SAndreas JaekelINSTALL_TARGET	= $(BINARY) $(ROOTMODULE) $(ROOT_CONFFILE)
54*b94833c4SAndreas Jaekel
55*b94833c4SAndreas Jaekel#
56*b94833c4SAndreas Jaekel#	Overrides and depends_on
57*b94833c4SAndreas Jaekel#
58*b94833c4SAndreas JaekelMODSTUBS_DIR	 = $(OBJS_DIR)
59*b94833c4SAndreas JaekelLDFLAGS		+= -dy -Nzfs
60*b94833c4SAndreas Jaekel
61*b94833c4SAndreas JaekelINC_PATH	+= -I$(UTSBASE)/common/fs/getgen
62*b94833c4SAndreas JaekelINC_PATH	+= -I$(UTSBASE)/common/fs/zfs
63*b94833c4SAndreas JaekelINC_PATH	+= -I$(SRC)/common
64*b94833c4SAndreas JaekelINC_PATH	+= -I$(COMMONBASE)/getgen
65*b94833c4SAndreas JaekelINC_PATH        += -I$(COMMONBASE)/zfs
66*b94833c4SAndreas Jaekel
67*b94833c4SAndreas Jaekel
68*b94833c4SAndreas JaekelC99MODE=	-xc99=%all
69*b94833c4SAndreas JaekelC99LMODE=	-Xc99=%all
70*b94833c4SAndreas Jaekel
71*b94833c4SAndreas Jaekel#
72*b94833c4SAndreas Jaekel# For now, disable these lint checks; maintainers should endeavor
73*b94833c4SAndreas Jaekel# to investigate and remove these for maximum lint coverage.
74*b94833c4SAndreas Jaekel# Please do not carry these forward to new Makefiles.
75*b94833c4SAndreas Jaekel#
76*b94833c4SAndreas JaekelLINTTAGS	+= -erroff=E_PTRDIFF_OVERFLOW
77*b94833c4SAndreas Jaekel
78*b94833c4SAndreas JaekelCERRWARN	+= -_gcc=-Wno-parentheses
79*b94833c4SAndreas JaekelCERRWARN	+= -_gcc=-Wno-uninitialized
80*b94833c4SAndreas Jaekel
81*b94833c4SAndreas Jaekel#
82*b94833c4SAndreas Jaekel#	Default build targets.
83*b94833c4SAndreas Jaekel#
84*b94833c4SAndreas Jaekel.KEEP_STATE:
85*b94833c4SAndreas Jaekel
86*b94833c4SAndreas Jaekeldef:		$(DEF_DEPS)
87*b94833c4SAndreas Jaekel
88*b94833c4SAndreas Jaekelall:		$(ALL_DEPS)
89*b94833c4SAndreas Jaekel
90*b94833c4SAndreas Jaekelclean:		$(CLEAN_DEPS)
91*b94833c4SAndreas Jaekel
92*b94833c4SAndreas Jaekelclobber:	$(CLOBBER_DEPS)
93*b94833c4SAndreas Jaekel
94*b94833c4SAndreas Jaekellint:		$(LINT_DEPS)
95*b94833c4SAndreas Jaekel
96*b94833c4SAndreas Jaekelmodlintlib:	$(MODLINTLIB_DEPS)
97*b94833c4SAndreas Jaekel
98*b94833c4SAndreas Jaekelclean.lint:	$(CLEAN_LINT_DEPS)
99*b94833c4SAndreas Jaekel
100*b94833c4SAndreas Jaekelinstall:	$(INSTALL_DEPS)
101*b94833c4SAndreas Jaekel
102*b94833c4SAndreas Jaekel#
103*b94833c4SAndreas Jaekel#	Include common targets.
104*b94833c4SAndreas Jaekel#
105*b94833c4SAndreas Jaekelinclude ../Makefile.targ
106