CTS Eclipse Classpath File Generator
Add a script that combine the classpath under development/ide/eclipse
with a .classpath file under cts/development/ide/eclipse that has
the CTS packages. Run the following in your ANDROID_BUILD_TOP to
generate a classpath for Eclipse that has the CTS packages:
./cts/development/ide/eclipse/genclasspath.sh > .classpath
Change-Id: I0cd0cecdf594d99e52b1b78d8c50f80bbf855d0f
diff --git a/development/ide/eclipse/genclasspath.sh b/development/ide/eclipse/genclasspath.sh
new file mode 100755
index 0000000..00ee9b3
--- /dev/null
+++ b/development/ide/eclipse/genclasspath.sh
@@ -0,0 +1,18 @@
+#!/bin/bash
+
+# Outputs a classpath file containing classpaths from development/ide/eclipse
+# and additional classpaths from cts/development/ide/eclipse.
+#
+# From your $ANDROID_BUILD_TOP directory:
+# ./cts/development/ide/eclipse/genclasspath.sh > .classpath
+
+if [[ -z $ANDROID_BUILD_TOP ]]; then
+ echo "Run 'lunch' to set \$ANDROID_BUILD_TOP" >&2
+ exit 1
+fi
+
+echo '<?xml version="1.0" encoding="UTF-8"?>'
+echo '<classpath>'
+cat $ANDROID_BUILD_TOP/cts/development/ide/eclipse/.classpath | grep classpathentry
+cat $ANDROID_BUILD_TOP/development/ide/eclipse/.classpath | grep classpathentry
+echo '</classpath>'