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