hotspot/src/share/tools/ProjectCreator/WinGammaPlatformVC10.java
changeset 22734 41757c1f3946
parent 19270 607d97508c60
child 26293 5c7a054e59fe
--- a/hotspot/src/share/tools/ProjectCreator/WinGammaPlatformVC10.java	Thu Jan 30 09:41:45 2014 +0100
+++ b/hotspot/src/share/tools/ProjectCreator/WinGammaPlatformVC10.java	Thu Jan 30 14:12:22 2014 -0800
@@ -161,7 +161,18 @@
         for (BuildConfig cfg : allConfigs) {
             startTag(cfg, "PropertyGroup");
             tagData("LocalDebuggerCommand", cfg.get("JdkTargetRoot") + "\\bin\\java.exe");
-            tagData("LocalDebuggerCommandArguments", "-XXaltjvm=$(TargetDir) -Dsun.java.launcher=gamma");
+            // The JVM loads some libraries using a path relative to
+            // itself because it expects to be in a JRE or a JDK. The java
+            // launcher's '-XXaltjvm=' option allows the JVM to be outside
+            // the JRE or JDK so '-Dsun.java.launcher.is_altjvm=true'
+            // forces a fake JAVA_HOME relative path to be used to
+            // find the other libraries. The '-XX:+PauseAtExit' option
+            // causes the VM to wait for key press before exiting; this
+            // allows any stdout or stderr messages to be seen before
+            // the cmdtool exits.
+            tagData("LocalDebuggerCommandArguments", "-XXaltjvm=$(TargetDir) "
+                    + "-Dsun.java.launcher.is_altjvm=true "
+                    + "-XX:+UnlockDiagnosticVMOptions -XX:+PauseAtExit");
             tagData("LocalDebuggerEnvironment", "JAVA_HOME=" + cfg.get("JdkTargetRoot"));
             endTag();
         }