Phase 2 of readying samples for distro.
- Added a top-level ant file for the distro/samples to build or produce eclipse projects in bulk.
- gwt-dev is now an explicit dependency so that Showcase can compile
Review by: amitmanjhi (TBR)
git-svn-id: https://google-web-toolkit.googlecode.com/svn/releases/1.6@4573 8db76d5a-ed1c-0410-87a9-c151d255dfc7
diff --git a/distro-source/core/src/samples/build.xml b/distro-source/core/src/samples/build.xml
new file mode 100644
index 0000000..0a77f56
--- /dev/null
+++ b/distro-source/core/src/samples/build.xml
@@ -0,0 +1,30 @@
+<project name="samples" default="build" basedir=".">
+
+ <target name="-do">
+ <ant target="${target}" dir="DynaTable"/>
+ <ant target="${target}" dir="Hello"/>
+ <ant target="${target}" dir="I18N"/>
+ <ant target="${target}" dir="JSON"/>
+ <ant target="${target}" dir="Mail"/>
+ <ant target="${target}" dir="Showcase"/>
+ <ant target="${target}" dir="SimpleXML"/>
+ </target>
+
+ <target name="build" description="Build all samples">
+ <antcall target="-do">
+ <param name="target" value="build" />
+ </antcall>
+ </target>
+
+ <target name="eclipse.generate" description="Generate eclipse projects for all samples">
+ <antcall target="-do">
+ <param name="target" value="eclipse.generate" />
+ </antcall>
+ </target>
+
+ <target name="clean" description="Clean all samples">
+ <antcall target="-do">
+ <param name="target" value="clean" />
+ </antcall>
+ </target>
+</project>
diff --git a/user/src/com/google/gwt/user/tools/.classpathsrc b/user/src/com/google/gwt/user/tools/.classpathsrc
index d2b73b6..570ab72 100644
--- a/user/src/com/google/gwt/user/tools/.classpathsrc
+++ b/user/src/com/google/gwt/user/tools/.classpathsrc
@@ -2,6 +2,7 @@
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry kind="lib" path="@gwtUserPath"/>
+ <classpathentry kind="lib" path="@gwtDevPath"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/3"/>
<classpathentry kind="output" path="war/WEB-INF/classes"/>
diff --git a/user/src/com/google/gwt/user/tools/App.launchsrc b/user/src/com/google/gwt/user/tools/App.launchsrc
index 92200c3..b5ea711 100644
--- a/user/src/com/google/gwt/user/tools/App.launchsrc
+++ b/user/src/com/google/gwt/user/tools/App.launchsrc
@@ -6,7 +6,6 @@
<listEntry value="<?xml version="1.0" encoding="UTF-8"?> <runtimeClasspathEntry containerPath="org.eclipse.jdt.launching.JRE_CONTAINER" javaProject="@moduleShortName" path="1" type="4"/> "/>
<listEntry value="<?xml version="1.0" encoding="UTF-8"?> <runtimeClasspathEntry internalArchive="/@moduleShortName/src" path="3" type="2"/> "/>
<listEntry value="<?xml version="1.0" encoding="UTF-8"?> <runtimeClasspathEntry id="org.eclipse.jdt.launching.classpathentry.defaultClasspath"> <memento project="@moduleShortName"/> </runtimeClasspathEntry> "/>
-<listEntry value="<?xml version="1.0" encoding="UTF-8"?> <runtimeClasspathEntry externalArchive="@gwtDevPath" path="3" type="2"/> "/>
</listAttribute>
<stringAttribute key="org.eclipse.jdt.launching.VM_ARGUMENTS" value="-Xmx256M@vmargs"/>
<stringAttribute key="org.eclipse.jdt.launching.PROGRAM_ARGUMENTS" value="-startupUrl @startupUrl @moduleName"/>
diff --git a/user/src/com/google/gwt/user/tools/WebAppCreator.java b/user/src/com/google/gwt/user/tools/WebAppCreator.java
index 7ba8afc..552d454 100644
--- a/user/src/com/google/gwt/user/tools/WebAppCreator.java
+++ b/user/src/com/google/gwt/user/tools/WebAppCreator.java
@@ -272,8 +272,7 @@
+ " <target name=\"eclipse.generate\" depends=\"libs\" description=\"Generate eclipse project\">\n"
+ " <java failonerror=\"true\" fork=\"true\" classname=\""
+ this.getClass().getName() + "\">\n" + " <classpath>\n"
- + " <pathelement location=\"" + gwtUserPath + "\"/>\n"
- + " <pathelement location=\"" + gwtDevPath + "\"/>\n"
+ + " <path refid=\"project.class.path\"/>\n"
+ " </classpath>\n" + " <arg value=\"-XonlyEclipse\"/>\n"
+ " <arg value=\"-ignore\"/>\n" + " <arg value=\""
+ moduleName + "\"/>\n" + " </java>\n" + " </target>";
diff --git a/user/src/com/google/gwt/user/tools/project.ant.xmlsrc b/user/src/com/google/gwt/user/tools/project.ant.xmlsrc
index 0b3f664..b050e83 100644
--- a/user/src/com/google/gwt/user/tools/project.ant.xmlsrc
+++ b/user/src/com/google/gwt/user/tools/project.ant.xmlsrc
@@ -4,6 +4,7 @@
<path id="project.class.path">
<pathelement location="war/WEB-INF/classes"/>
<pathelement location="@gwtUserPath"/>
+ <pathelement location="@gwtDevPath"/>
<!-- Add any additional non-server libs (such as JUnit) -->
<fileset dir="war/WEB-INF/lib">
<include name="**/*.jar"/>
@@ -32,7 +33,6 @@
<classpath>
<pathelement location="src"/>
<path refid="project.class.path"/>
- <pathelement location="@gwtDevPath"/>
</classpath>
<!-- add jvmarg -Xss16M or similar if you see a StackOverflowError -->
<jvmarg value="-Xmx256M"/>@antVmargs
@@ -45,7 +45,6 @@
<classpath>
<pathelement location="src"/>
<path refid="project.class.path"/>
- <pathelement location="@gwtDevPath"/>
</classpath>
<jvmarg value="-Xmx256M"/>@antVmargs
<arg value="-startupUrl"/>