Makefile 4.2 KB
Newer Older
D
duke 已提交
1
#
S
sla 已提交
2
# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
D
duke 已提交
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation.
#
# This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
# version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code).
#
# You should have received a copy of the GNU General Public License version
# 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
#
19 20 21
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
# or visit www.oracle.com if you need additional information or have any
# questions.
D
duke 已提交
22 23 24
#  
#

25 26 27 28
!ifdef LOCAL_MAKE
!include $(LOCAL_MAKE)
!endif

29

D
duke 已提交
30 31 32 33 34 35 36 37 38 39
WorkSpace=$(HOTSPOTWORKSPACE)

!ifdef ALT_BOOTDIR
BootStrapDir=$(ALT_BOOTDIR)
!else
!ifdef BOOTDIR
BootStrapDir=$(BOOTDIR)
!else
!ifdef JAVA_HOME
BootStrapDir=$(JAVA_HOME)
40 41 42 43
!else
!ifdef HOTSPOTJDKDIST
BootStrapDir=$(HOTSPOTJDKDIST)
!endif
D
duke 已提交
44 45 46 47
!endif
!endif
!endif

S
sla 已提交
48 49 50 51 52 53
# if hotspot-only build and/or OPENJDK isn't passed down, need to set OPENJDK
!ifndef OPENJDK
!if !exists($(WorkSpace)\src\closed)
OPENJDK=true
!endif
!endif
54 55


56
!include $(HOTSPOTWORKSPACE)/make/windows/makefiles/projectcreator.make
57
!include $(WorkSpace)/make/windows/makefiles/compile.make
D
duke 已提交
58 59

# Pick up rules for building JVMTI (JSR-163)
60
JvmtiOutDir=$(HOTSPOTBUILDSPACE)\$(Variant)\generated\jvmtifiles
61
!include $(HOTSPOTWORKSPACE)/make/windows/makefiles/jvmti.make
D
duke 已提交
62

S
sla 已提交
63 64 65 66
# Pick up rules for building trace
TraceOutDir=$(HOTSPOTBUILDSPACE)\$(Variant)\generated\tracefiles
!include $(HOTSPOTWORKSPACE)/make/windows/makefiles/trace.make

D
duke 已提交
67 68
!if "$(Variant)" == "compiler2"
# Pick up rules for building adlc
69
!include $(HOTSPOTWORKSPACE)/make/windows/makefiles/adlc.make
D
duke 已提交
70 71 72 73
!endif

!if "$(Variant)" == "tiered"
# Pick up rules for building adlc
74
!include $(HOTSPOTWORKSPACE)/make/windows/makefiles/adlc.make
D
duke 已提交
75 76
!endif

77 78
HS_INTERNAL_NAME=jvm

S
sla 已提交
79
default:: $(AdditionalTargets) $(JvmtiGeneratedFiles) $(TraceGeneratedFiles)
D
duke 已提交
80 81 82

!include $(HOTSPOTWORKSPACE)/make/hotspot_version

83
!if "$(USER_RELEASE_SUFFIX)" != ""
84
HOTSPOT_BUILD_VERSION = internal-$(USER_RELEASE_SUFFIX)
85
!else
86
HOTSPOT_BUILD_VERSION = internal
87
!endif
88 89 90 91
!if "$(HOTSPOT_RELEASE_VERSION)" != ""
HOTSPOT_RELEASE_VERSION="\\\"$(HOTSPOT_RELEASE_VERSION)\\\""
!else
HOTSPOT_RELEASE_VERSION="\\\"$(HS_MAJOR_VER).$(HS_MINOR_VER)-b$(HS_BUILD_NUMBER)-$(HOTSPOT_BUILD_VERSION)\\\""
D
duke 已提交
92 93
!endif
!if "$(JRE_RELEASE_VERSION)" != ""
94
JRE_RELEASE_VERSION="\\\"$(JRE_RELEASE_VERSION)\\\""
D
duke 已提交
95
!else
96
JRE_RELEASE_VERSION="\\\"$(JDK_MAJOR_VER).$(JDK_MINOR_VER).$(JDK_MICRO_VER)\\\""
D
duke 已提交
97 98 99 100 101
!endif

# Define HOTSPOT_VM_DISTRO if HOTSPOT_VM_DISTRO is set,
# and if it is not see if we have the src/closed directory
!if "$(HOTSPOT_VM_DISTRO)" != ""
102
HOTSPOT_VM_DISTRO=$(HOTSPOT_VM_DISTRO)
D
duke 已提交
103 104
!else
!if exists($(HOTSPOTWORKSPACE)\src\closed)
105
HOTSPOT_VM_DISTRO="\\\"Java HotSpot(TM)\\\""
D
duke 已提交
106
!else
107
HOTSPOT_VM_DISTRO="\\\"OpenJDK\\\""
D
duke 已提交
108 109 110
!endif
!endif

111 112
ReleaseOptions = -define HOTSPOT_RELEASE_VERSION=$(HOTSPOT_RELEASE_VERSION) -define JRE_RELEASE_VERSION=$(JRE_RELEASE_VERSION) -define HOTSPOT_VM_DISTRO=$(HOTSPOT_VM_DISTRO)
ProjectCreatorIDEOptions = $(ProjectCreatorIDEOptions) $(ReleaseOptions)
D
duke 已提交
113

114
$(HOTSPOTBUILDSPACE)/$(ProjectFile): $(HOTSPOTBUILDSPACE)/classes/ProjectCreator.class
I
iklam 已提交
115
	@if "$(MSC_VER)"=="1500" echo Make sure you have VS2008 SP1 or later, or you may see 'expanded command line too long'
116
	@$(RUN_JAVA) -Djava.class.path="$(HOTSPOTBUILDSPACE)/classes" ProjectCreator WinGammaPlatform$(VcVersion) $(ProjectCreatorIDEOptions)
D
duke 已提交
117 118

clean:
119
	@rm -rf $(HOTSPOTBUILDSPACE)/classes
120
	@rm -r $(HOTSPOTBUILDSPACE)/$(ProjectFile)
D
duke 已提交
121

122
$(HOTSPOTBUILDSPACE)/classes/ProjectCreator.class: $(ProjectCreatorSources)
D
duke 已提交
123 124
	@if exist $(HOTSPOTBUILDSPACE)\classes rmdir /s /q $(HOTSPOTBUILDSPACE)\classes
	@mkdir $(HOTSPOTBUILDSPACE)\classes
125
	@$(COMPILE_JAVAC) -classpath $(HOTSPOTWORKSPACE)\src\share\tools\ProjectCreator -d $(HOTSPOTBUILDSPACE)/classes $(ProjectCreatorSources)
D
duke 已提交
126 127

FORCE: