hotspot/make/windows/makefiles/launcher.make
author mikael
Tue, 09 Oct 2012 10:09:34 -0700
changeset 13963 e5b53c306fb5
parent 11721 dcd1f62c9caf
permissions -rw-r--r--
7197424: update copyright year to match last edit in jdk8 hotspot repository Summary: Update copyright year to 2012 for relevant files Reviewed-by: dholmes, coleenp
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
8482
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
     1
#
13963
e5b53c306fb5 7197424: update copyright year to match last edit in jdk8 hotspot repository
mikael
parents: 11721
diff changeset
     2
# Copyright (c) 2010, 2012, Oracle and/or its affiliates. All rights reserved.
8482
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
     3
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
     4
#
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
     5
# This code is free software; you can redistribute it and/or modify it
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
     6
# under the terms of the GNU General Public License version 2 only, as
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
     7
# published by the Free Software Foundation.
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
     8
#
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
     9
# This code is distributed in the hope that it will be useful, but WITHOUT
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    10
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    11
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    12
# version 2 for more details (a copy is included in the LICENSE file that
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    13
# accompanied this code).
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    14
#
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    15
# You should have received a copy of the GNU General Public License version
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    16
# 2 along with this work; if not, write to the Free Software Foundation,
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    17
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    18
#
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    19
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    20
# or visit www.oracle.com if you need additional information or have any
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    21
# questions.
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    22
#  
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    23
#
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    24
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    25
11721
dcd1f62c9caf 7141242: build-infra merge: Rename CPP->CXX and LINK->LD
erikj
parents: 8921
diff changeset
    26
LAUNCHER_FLAGS=$(CXX_FLAGS) $(ARCHFLAG) \
8482
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    27
	/D FULL_VERSION=\"$(HOTSPOT_RELEASE_VERSION)\" \
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    28
	/D JDK_MAJOR_VERSION=\"$(JDK_MAJOR_VERSION)\" \
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    29
	/D JDK_MINOR_VERSION=\"$(JDK_MINOR_VERSION)\" \
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    30
	/D GAMMA \
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    31
	/D LAUNCHER_TYPE=\"gamma\" \
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    32
	/D _CRT_SECURE_NO_WARNINGS \
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    33
	/D _CRT_SECURE_NO_DEPRECATE \
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    34
	/D LINK_INTO_LIBJVM \
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    35
	/I $(WorkSpace)\src\os\windows\launcher \
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    36
	/I $(WorkSpace)\src\share\tools\launcher \
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    37
	/I $(WorkSpace)\src\share\vm\prims \
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    38
	/I $(WorkSpace)\src\share\vm \
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    39
	/I $(WorkSpace)\src\cpu\$(Platform_arch)\vm \
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    40
	/I $(WorkSpace)\src\os\windows\vm
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    41
11721
dcd1f62c9caf 7141242: build-infra merge: Rename CPP->CXX and LINK->LD
erikj
parents: 8921
diff changeset
    42
LD_FLAGS=/manifest $(HS_INTERNAL_NAME).lib kernel32.lib user32.lib /nologo /machine:$(MACHINE) /map /debug /subsystem:console 
8482
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    43
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    44
!if "$(COMPILER_NAME)" == "VS2005"
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    45
# This VS2005 compiler has /GS as a default and requires bufferoverflowU.lib
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    46
#    on the link command line, otherwise we get missing __security_check_cookie
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    47
#    externals at link time. Even with /GS-, you need bufferoverflowU.lib.
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    48
BUFFEROVERFLOWLIB = bufferoverflowU.lib
11721
dcd1f62c9caf 7141242: build-infra merge: Rename CPP->CXX and LINK->LD
erikj
parents: 8921
diff changeset
    49
LD_FLAGS = $(LD_FLAGS) $(BUFFEROVERFLOWLIB)
8482
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    50
!endif
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    51
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    52
!if "$(COMPILER_NAME)" == "VS2010" && "$(BUILDARCH)" == "i486"
11721
dcd1f62c9caf 7141242: build-infra merge: Rename CPP->CXX and LINK->LD
erikj
parents: 8921
diff changeset
    53
LD_FLAGS = /SAFESEH $(LD_FLAGS)
8482
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    54
!endif
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    55
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    56
LAUNCHERDIR = $(WorkSpace)/src/os/windows/launcher
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    57
LAUNCHERDIR_SHARE = $(WorkSpace)/src/share/tools/launcher
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    58
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    59
OUTDIR = launcher
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    60
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    61
{$(LAUNCHERDIR)}.c{$(OUTDIR)}.obj:
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    62
	-mkdir $(OUTDIR) 2>NUL >NUL
11721
dcd1f62c9caf 7141242: build-infra merge: Rename CPP->CXX and LINK->LD
erikj
parents: 8921
diff changeset
    63
        $(CXX) $(LAUNCHER_FLAGS) /c /Fo$@ $<
8482
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    64
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    65
{$(LAUNCHERDIR_SHARE)}.c{$(OUTDIR)}.obj:
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    66
	-mkdir $(OUTDIR) 2>NUL >NUL
11721
dcd1f62c9caf 7141242: build-infra merge: Rename CPP->CXX and LINK->LD
erikj
parents: 8921
diff changeset
    67
        $(CXX) $(LAUNCHER_FLAGS) /c /Fo$@ $<
8482
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    68
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    69
$(OUTDIR)\*.obj: $(LAUNCHERDIR)\*.c $(LAUNCHERDIR)\*.h $(LAUNCHERDIR_SHARE)\*.c $(LAUNCHERDIR_SHARE)\*.h
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    70
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    71
launcher: $(OUTDIR)\java.obj $(OUTDIR)\java_md.obj $(OUTDIR)\jli_util.obj
2c8eb211176d 7017110: Add /SAFESEH to links on windows 32bit to verify safe exceptions
zgu
parents: 7452
diff changeset
    72
	echo $(JAVA_HOME) > jdkpath.txt  
11721
dcd1f62c9caf 7141242: build-infra merge: Rename CPP->CXX and LINK->LD
erikj
parents: 8921
diff changeset
    73
	$(LD) $(LD_FLAGS) /out:hotspot.exe $**