1#
2# CDDL HEADER START
3#
4# The contents of this file are subject to the terms of the
5# Common Development and Distribution License (the "License").
6# You may not use this file except in compliance with the License.
7#
8# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9# or http://www.opensolaris.org/os/licensing.
10# See the License for the specific language governing permissions
11# and limitations under the License.
12#
13# When distributing Covered Code, include this CDDL HEADER in each
14# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15# If applicable, add the following below this CDDL HEADER, with the
16# fields enclosed by brackets "[]" replaced with your own identifying
17# information: Portions Copyright [yyyy] [name of copyright owner]
18#
19# CDDL HEADER END
20#
21#
22# uts/i86pc/Makefile.hvm
23#
24# Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
25# Use is subject to license terms.
26#
27#ident	"%Z%%M%	%I%	%E% SMI"
28#
29#	This makefile provides support for building PV drivers that run
30#	in an HVM environment.
31#
32
33ROOT_HVM_DIR		= $(ROOT)/platform/i86hvm
34ROOT_HVM_MOD_DIR	= $(ROOT_HVM_DIR)/kernel
35ROOT_HVM_DRV_DIR_32	= $(ROOT_HVM_MOD_DIR)/drv
36ROOT_HVM_DRV_DIR_64	= $(ROOT_HVM_MOD_DIR)/drv/$(MACH64)
37ROOT_HVM_DRV_DIR	= $(ROOT_HVM_DRV_DIR_$(CLASS))
38ROOT_HVM_MISC_DIR_32	= $(ROOT_HVM_MOD_DIR)/misc
39ROOT_HVM_MISC_DIR_64	= $(ROOT_HVM_MOD_DIR)/misc/$(MACH64)
40ROOT_HVM_MISC_DIR	= $(ROOT_HVM_MISC_DIR_$(CLASS))
41USR_HVM_DIR		= $(ROOT)/usr/platform/i86hvm
42
43#
44# Indicate that we are building for the i86hvm semi-platform
45#
46CPPFLAGS	+= -DXPV_HVM_DRIVER
47ASFLAGS		+= -DXPV_HVM_DRIVER
48
49#
50#	Installation targets and rules:
51#
52$(ROOT_HVM_DIR):
53	-$(INS.dir.root.sys)
54
55$(ROOT_HVM_MOD_DIR):		$(ROOT_HVM_DIR)
56	-$(INS.dir.root.sys)
57
58$(ROOT_HVM_DRV_DIR):		$(ROOT_MOD_DIR)
59	-$(INS.dir.root.sys)
60
61$(ROOT_HVM_MISC_DIR):		$(ROOT_MOD_DIR)
62	-$(INS.dir.root.sys)
63
64$(ROOT_HVM_MOD_DIR)/%:		$(OBJS_DIR)/% $(ROOT_HVM_MOD_DIR) FRC
65	$(INS.file)
66
67$(ROOT_HVM_DRV_DIR)/%:		$(OBJS_DIR)/% $(ROOT_HVM_DRV_DIR) FRC
68	$(INS.file)
69
70$(ROOT_HVM_MISC_DIR)/%:		$(OBJS_DIR)/% $(ROOT_HVM_MISC_DIR) FRC
71	$(INS.file)
72
73$(USR_HVM_DIR):
74	-$(INS.dir.root.sys)
75
76INSTALL_DEPS += $(ROOT_HVM_DIR) $(USR_HVM_DIR)
77