summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorAndroid (Google) Code Review <android-gerrit@google.com>2009-07-31 11:01:45 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2009-07-31 11:01:45 -0700
commit60a735fda1f9d7c24c577853304d486b0109632f (patch)
treeff503ef28e935ae5534105ce806a16df560032a2 /tools
parentf19a3083e77eeab2026436e4d04329d4b5aba8bf (diff)
parent1d3395b25b914121170e727be1b9a43452fc681a (diff)
downloadandroid_development-60a735fda1f9d7c24c577853304d486b0109632f.tar.gz
android_development-60a735fda1f9d7c24c577853304d486b0109632f.tar.bz2
android_development-60a735fda1f9d7c24c577853304d486b0109632f.zip
Merge change 9352 into donut
* changes: ADT: fix PreCompilerBuilder to use minSdkVersion as a string, not an int.
Diffstat (limited to 'tools')
-rw-r--r--tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/build/PreCompilerBuilder.java12
1 files changed, 9 insertions, 3 deletions
diff --git a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/build/PreCompilerBuilder.java b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/build/PreCompilerBuilder.java
index 2ba0b0331..2f733fa9c 100644
--- a/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/build/PreCompilerBuilder.java
+++ b/tools/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/build/PreCompilerBuilder.java
@@ -291,6 +291,9 @@ public class PreCompilerBuilder extends BaseBuilder {
// This interrupts the build. The next builders will not run.
stopBuild(msg);
+
+ // TODO: document whether code below that uses manifest (which is now guaranteed
+ // to be null) will actually be executed or not.
}
// lets check the XML of the manifest first, if that hasn't been done by the
@@ -342,7 +345,7 @@ public class PreCompilerBuilder extends BaseBuilder {
} else if (minSdkValue < projectVersion.getApiLevel()) {
// integer minSdk is not high enough for the target => warning
String msg = String.format(
- "Manifest min SDK version (%1$d) is lower than project target API level (%2$d)",
+ "Manifest min SDK version (%1$s) is lower than project target API level (%2$d)",
minSdkVersion, projectVersion.getApiLevel());
AdtPlugin.printBuildToConsole(AdtConstants.BUILD_VERBOSE, project, msg);
BaseProjectHelper.addMarker(manifest, AdtConstants.MARKER_ADT, msg,
@@ -383,11 +386,14 @@ public class PreCompilerBuilder extends BaseBuilder {
// This interrupts the build. The next builders will not run.
stopBuild(msg);
+
+ // TODO: document whether code below that uses javaPackage (which is now guaranteed
+ // to be null) will actually be executed or not.
}
// at this point we have the java package. We need to make sure it's not a different
// package than the previous one that were built.
- if (javaPackage.equals(mManifestPackage) == false) {
+ if (javaPackage != null && javaPackage.equals(mManifestPackage) == false) {
// The manifest package has changed, the user may want to update
// the launch configuration
if (mManifestPackage != null) {
@@ -421,7 +427,7 @@ public class PreCompilerBuilder extends BaseBuilder {
// get the file system path
IPath outputLocation = mGenFolder.getLocation();
IPath resLocation = resFolder.getLocation();
- IPath manifestLocation = manifest.getLocation();
+ IPath manifestLocation = manifest == null ? null : manifest.getLocation();
// those locations have to exist for us to do something!
if (outputLocation != null && resLocation != null