Add support for building AILD files.

This brings in the SourceProcessor, SourceGenerator and
DependencyGraph from the ant tasks. The dependency graph
is only needed because Gradle doesn't give us the list
of changed files just yet.

Change-Id: I4e9c8ccb032078529516af29b2287b21adac05cc
diff --git a/testapps/aidl/build.gradle b/testapps/aidl/build.gradle
new file mode 100644
index 0000000..be4c4d9
--- /dev/null
+++ b/testapps/aidl/build.gradle
@@ -0,0 +1,17 @@
+//
+// A basic Android application that follows all the conventions
+//
+buildscript {
+    repositories {
+        maven { url '../../repo' }
+    }
+    dependencies {
+        classpath 'com.android.build:gradle-android:0.1-SNAPSHOT'
+    }
+}
+apply plugin: 'android'
+
+android {
+    target = "android-15"
+
+}
\ No newline at end of file
diff --git a/testapps/aidl/src/main/AndroidManifest.xml b/testapps/aidl/src/main/AndroidManifest.xml
new file mode 100644
index 0000000..4cf7553
--- /dev/null
+++ b/testapps/aidl/src/main/AndroidManifest.xml
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="utf-8"?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+      android:versionCode="1"
+      android:versionName="1.0" package="com.android.tests.basicprojectwithaidl">
+    <application android:label="@string/app_name" android:icon="@drawable/icon">
+        <activity android:name="com.android.tests.basicprojectwithaidlwithaidl.Main"
+                  android:label="@string/app_name">
+            <intent-filter>
+                <action android:name="android.intent.action.MAIN" />
+                <category android:name="android.intent.category.LAUNCHER" />
+            </intent-filter>
+        </activity>
+    </application>
+    <uses-sdk android:minSdkVersion="AOSP"/>
+</manifest>
diff --git a/testapps/aidl/src/main/aidl/com/android/tests/basicprojectwithaidl/ITest.aidl b/testapps/aidl/src/main/aidl/com/android/tests/basicprojectwithaidl/ITest.aidl
new file mode 100644
index 0000000..9b81031
--- /dev/null
+++ b/testapps/aidl/src/main/aidl/com/android/tests/basicprojectwithaidl/ITest.aidl
@@ -0,0 +1,7 @@
+package com.android.tests.basicprojectwithaidl;
+
+interface ITest {
+    Rect getRect();
+    int getInt();
+}
+
diff --git a/testapps/aidl/src/main/aidl/com/android/tests/basicprojectwithaidl/Rect.aidl b/testapps/aidl/src/main/aidl/com/android/tests/basicprojectwithaidl/Rect.aidl
new file mode 100644
index 0000000..734cf77
--- /dev/null
+++ b/testapps/aidl/src/main/aidl/com/android/tests/basicprojectwithaidl/Rect.aidl
@@ -0,0 +1,5 @@
+package com.android.tests.basicprojectwithaidl;
+
+// Declare Rect so AIDL can find it and knows that it implements
+// the parcelable protocol.
+parcelable Rect;
\ No newline at end of file
diff --git a/testapps/aidl/src/main/java/com/android/tests/basicprojectwithaidl/Main.java b/testapps/aidl/src/main/java/com/android/tests/basicprojectwithaidl/Main.java
new file mode 100644
index 0000000..eaed510
--- /dev/null
+++ b/testapps/aidl/src/main/java/com/android/tests/basicprojectwithaidl/Main.java
@@ -0,0 +1,15 @@
+package com.android.tests.basicprojectwithaidl;
+
+import android.app.Activity;
+import android.os.Bundle;
+
+public class Main extends Activity
+{
+    /** Called when the activity is first created. */
+    @Override
+    public void onCreate(Bundle savedInstanceState)
+    {
+        super.onCreate(savedInstanceState);
+        setContentView(R.layout.main);
+    }
+}
diff --git a/testapps/aidl/src/main/java/com/android/tests/basicprojectwithaidl/Rect.java b/testapps/aidl/src/main/java/com/android/tests/basicprojectwithaidl/Rect.java
new file mode 100644
index 0000000..8e16926
--- /dev/null
+++ b/testapps/aidl/src/main/java/com/android/tests/basicprojectwithaidl/Rect.java
@@ -0,0 +1,52 @@
+package com.android.tests.basicprojectwithaidl;
+
+import android.os.Parcel;
+import android.os.Parcelable;
+
+public class Rect implements Parcelable {
+    public int left;
+    public int top;
+    public int right;
+    public int bottom;
+
+    public static final Parcelable.Creator<Rect> CREATOR = new Parcelable.Creator<Rect>() {
+        public Rect createFromParcel(Parcel in) {
+            return new Rect(in);
+        }
+
+        public Rect[] newArray(int size) {
+            return new Rect[size];
+        }
+    };
+
+    public Rect() {
+    }
+
+    private Rect(Parcel in) {
+        readFromParcel(in);
+    }
+
+    public void writeToParcel(Parcel out) {
+        out.writeInt(left);
+        out.writeInt(top);
+        out.writeInt(right);
+        out.writeInt(bottom);
+    }
+
+    public void readFromParcel(Parcel in) {
+        left = in.readInt();
+        top = in.readInt();
+        right = in.readInt();
+        bottom = in.readInt();
+    }
+
+    public int describeContents() {
+        // TODO Auto-generated method stub
+        return 0;
+    }
+
+    public void writeToParcel(Parcel arg0, int arg1) {
+        // TODO Auto-generated method stub
+
+    }
+}
diff --git a/testapps/aidl/src/main/res/drawable/icon.png b/testapps/aidl/src/main/res/drawable/icon.png
new file mode 100644
index 0000000..a07c69f
--- /dev/null
+++ b/testapps/aidl/src/main/res/drawable/icon.png
Binary files differ
diff --git a/testapps/aidl/src/main/res/layout/main.xml b/testapps/aidl/src/main/res/layout/main.xml
new file mode 100644
index 0000000..783e4a0
--- /dev/null
+++ b/testapps/aidl/src/main/res/layout/main.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:orientation="vertical"
+    android:layout_width="fill_parent"
+    android:layout_height="fill_parent"
+    >
+<TextView
+    android:layout_width="fill_parent"
+    android:layout_height="wrap_content"
+    android:text="Basic Project"
+    />
+</LinearLayout>
+
diff --git a/testapps/aidl/src/main/res/values/strings.xml b/testapps/aidl/src/main/res/values/strings.xml
new file mode 100644
index 0000000..a7322d3
--- /dev/null
+++ b/testapps/aidl/src/main/res/values/strings.xml
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+    <string name="app_name">basicProject</string>
+</resources>
diff --git a/testapps/applibtest/lib/src/main/aidl/com/android/tests/basicprojectwithaidl/ITest.aidl b/testapps/applibtest/lib/src/main/aidl/com/android/tests/basicprojectwithaidl/ITest.aidl
new file mode 100644
index 0000000..9b81031
--- /dev/null
+++ b/testapps/applibtest/lib/src/main/aidl/com/android/tests/basicprojectwithaidl/ITest.aidl
@@ -0,0 +1,7 @@
+package com.android.tests.basicprojectwithaidl;
+
+interface ITest {
+    Rect getRect();
+    int getInt();
+}
+
diff --git a/testapps/applibtest/lib/src/main/aidl/com/android/tests/basicprojectwithaidl/Rect.aidl b/testapps/applibtest/lib/src/main/aidl/com/android/tests/basicprojectwithaidl/Rect.aidl
new file mode 100644
index 0000000..734cf77
--- /dev/null
+++ b/testapps/applibtest/lib/src/main/aidl/com/android/tests/basicprojectwithaidl/Rect.aidl
@@ -0,0 +1,5 @@
+package com.android.tests.basicprojectwithaidl;
+
+// Declare Rect so AIDL can find it and knows that it implements
+// the parcelable protocol.
+parcelable Rect;
\ No newline at end of file