7008378: javac bootstrap launcher fails on cygwin when called via an absolute path
authorjjh
Tue, 21 Dec 2010 16:29:10 -0800
changeset 7843 1103fac3fb5a
parent 7842 5de9ea98089d
child 7844 af81ef38cfa6
7008378: javac bootstrap launcher fails on cygwin when called via an absolute path Summary: Use cygpath if it is cygwin Reviewed-by: ksrini
langtools/make/Makefile
langtools/make/build.xml
langtools/src/share/bin/launcher.sh-template
--- a/langtools/make/Makefile	Sat Dec 18 09:38:39 2010 -0800
+++ b/langtools/make/Makefile	Tue Dec 21 16:29:10 2010 -0800
@@ -187,7 +187,7 @@
 clobber: clean
 
 # All ant targets of interest
-ANT_TARGETS = build clean sanity post-sanity diagnostics # for now
+ANT_TARGETS = build clean sanity post-sanity diagnostics build-all-tools  # for now
 
 # Create diagnostics log (careful, ant 1.8.0 -diagnostics always does an exit 1)
 $(OUTPUTDIR)/build/ant-diagnostics.log:
--- a/langtools/make/build.xml	Sat Dec 18 09:38:39 2010 -0800
+++ b/langtools/make/build.xml	Tue Dec 21 16:29:10 2010 -0800
@@ -327,6 +327,7 @@
         <!-- can override the following on the command line if desired. -->
         <property name="diags.examples.out" location="${build.dir}/diag-examples/diags-examples.html"/>
         <mkdir dir="${build.dir}/diag-examples/classes"/>
+<echo message="jj: diags-examples dist.bin.dir ${dist.bin.dir}/javac"/>
         <javac fork="true"
             executable="${dist.bin.dir}/javac"
             srcdir="test/tools/javac/diags"
@@ -741,6 +742,7 @@
                 <pcompile srcdir="@{gensrc.dir}"
                           destdir="@{gensrc.dir}"
                           includes="**/*.properties"/>
+<echo message="jj: -def-build-classes @java.home: @{java.home}/bin/javac"/>
                 <javac fork="true"
                        executable="@{java.home}/bin/javac"
                        srcdir="${src.classes.dir}:@{gensrc.dir}"
@@ -808,6 +810,8 @@
 
     <target name="-def-pcompile">
         <mkdir dir="${build.toolclasses.dir}"/>
+<echo message="jj: -def-pcompile boot.java.home ${boot.java.home}/bin/javac"/>
+
         <javac fork="true"
                source="${boot.javac.source}"
                target="${boot.javac.target}"
@@ -823,6 +827,8 @@
 
     <target name="-def-genstubs" depends="build-bootstrap-javac" if="require.import.jdk.stubs">
         <mkdir dir="${build.toolclasses.dir}"/>
+<echo message="jj: -def-genstubs boot.java.home ${boot.java.home}/bin/javac"/>
+
         <javac fork="true"
                source="${boot.javac.source}"
                target="${boot.javac.target}"
--- a/langtools/src/share/bin/launcher.sh-template	Sat Dec 18 09:38:39 2010 -0800
+++ b/langtools/src/share/bin/launcher.sh-template	Tue Dec 21 16:29:10 2010 -0800
@@ -26,6 +26,12 @@
 #
 
 mydir="`dirname $0`"
+case `uname -s` in
+    CYGWIN*)
+      mydir=`cygpath -m $mydir`
+      ;;
+esac
+
 mylib="`dirname $mydir`"/lib
 
 # By default, put the jar file and its dependencies on the bootclasspath.