]> git.saurik.com Git - android/aapt.git/blobdiff - Main.cpp
am 42f90ca5: Merge "Fix aapt dump badging to support xlarge screens." into gingerbread
[android/aapt.git] / Main.cpp
index b0c6e3975b51629e926c7e305a9f505493035860..f457cc8b3323be8f803a8aa75b19c877b971c29e 100644 (file)
--- a/Main.cpp
+++ b/Main.cpp
@@ -62,6 +62,7 @@ void usage(void)
         "        [--rename-manifest-package PACKAGE] \\\n"
         "        [--rename-instrumentation-target-package PACKAGE] \\\n"
         "        [--utf16] [--auto-add-overlay] \\\n"
+        "        [--max-res-version VAL] \\\n"
         "        [-I base-package [-I base-package ...]] \\\n"
         "        [-A asset-source-dir]  [-G class-list-file] [-P public-definitions-file] \\\n"
         "        [-S resource-sources [-S resource-sources ...]] "
@@ -128,6 +129,8 @@ void usage(void)
         "       higher, the default encoding for resources will be in UTF-8.\n"
         "   --target-sdk-version\n"
         "       inserts android:targetSdkVersion in to manifest.\n"
+        "   --max-res-version\n"
+        "       ignores versioned resource directories above the given value.\n"
         "   --values\n"
         "       when used with \"dump resources\" also includes resource values.\n"
         "   --version-code\n"
@@ -416,6 +419,15 @@ int main(int argc, char* const argv[])
                         goto bail;
                     }
                     bundle.setMaxSdkVersion(argv[0]);
+                } else if (strcmp(cp, "-max-res-version") == 0) {
+                    argc--;
+                    argv++;
+                    if (!argc) {
+                        fprintf(stderr, "ERROR: No argument supplied for '--max-res-version' option\n");
+                        wantUsage = true;
+                        goto bail;
+                    }
+                    bundle.setMaxResVersion(argv[0]);
                 } else if (strcmp(cp, "-version-code") == 0) {
                     argc--;
                     argv++;