Add "dumpapi.no_license" to omit license in dumps
A new property to control license header in dumps is added to
aidl_interface module.
When set to true, --dumpapi dumps without license headers.
This can be useful to avoid merge conflicts for projects which should
work with older AIDL compiler.
Bug: 179449077
Test: m test-piece-4-update-api (with no_license:true)
Change-Id: I0e72ee90085e643caa681214639f8c1f6fcde8f3
diff --git a/options.cpp b/options.cpp
index 97eb6b0..b383052 100644
--- a/options.cpp
+++ b/options.cpp
@@ -215,6 +215,7 @@
{"preprocess", no_argument, 0, 's'},
#ifndef _WIN32
{"dumpapi", no_argument, 0, 'u'},
+ {"no_license", no_argument, 0, 'x'},
{"checkapi", optional_argument, 0, 'A'},
#endif
{"apimapping", required_argument, 0, 'i'},
@@ -280,6 +281,9 @@
task_ = Options::Task::DUMP_API;
}
break;
+ case 'x':
+ dump_no_license_ = true;
+ break;
case 'A':
if (task_ != Options::Task::UNSPECIFIED) {
task_ = Options::Task::CHECK_API;