aboutsummaryrefslogtreecommitdiffstats
path: root/java
diff options
context:
space:
mode:
authorJiyong Park <jiyong@google.com>2018-05-12 22:21:20 +0900
committerJiyong Park <jiyong@google.com>2018-05-12 22:22:34 +0900
commiteeb8a6474c83327fb495d7ef4cf4b51f3f55a495 (patch)
tree7ae266632f4271b73025533631b5c31acfb20803 /java
parent9623892890cedf219e3f85dc379a186df841a896 (diff)
downloadandroid_build_soong-eeb8a6474c83327fb495d7ef4cf4b51f3f55a495.tar.gz
android_build_soong-eeb8a6474c83327fb495d7ef4cf4b51f3f55a495.tar.bz2
android_build_soong-eeb8a6474c83327fb495d7ef4cf4b51f3f55a495.zip
Fix some minor bugs for droiddoc
1) typo: check-api -> checkapi 2) newlines in the error messages are correctly emitted Bug: 77575606 Bug: 78034256 Test: m -j checkapi Change-Id: Ibeef4d9f4f7f2ca48c29c23b1784efa6aa53a364
Diffstat (limited to 'java')
-rw-r--r--java/androidmk.go2
-rw-r--r--java/droiddoc.go12
2 files changed, 10 insertions, 4 deletions
diff --git a/java/androidmk.go b/java/androidmk.go
index 5a4a082b..88dc6ef3 100644
--- a/java/androidmk.go
+++ b/java/androidmk.go
@@ -292,7 +292,7 @@ func (ddoc *Droiddoc) AndroidMk() android.AndroidMkData {
ddoc.checkCurrentApiTimestamp.String())
fmt.Fprintln(w, ".PHONY: checkapi")
- fmt.Fprintln(w, "check-api:",
+ fmt.Fprintln(w, "checkapi:",
ddoc.checkCurrentApiTimestamp.String())
fmt.Fprintln(w, ".PHONY: droidcore")
diff --git a/java/droiddoc.go b/java/droiddoc.go
index 202f22bc..b34c3936 100644
--- a/java/droiddoc.go
+++ b/java/droiddoc.go
@@ -50,7 +50,7 @@ var (
blueprint.RuleParams{
Command: `( ${config.ApiCheckCmd} -JXmx1024m -J"classpath $classpath" $opts ` +
`$apiFile $apiFileToCheck $removedApiFile $removedApiFileToCheck ` +
- `&& touch $out ) || (echo $msg ; exit 38)`,
+ `&& touch $out ) || (echo -e "$msg" ; exit 38)`,
CommandDeps: []string{
"${config.ApiCheckCmd}",
},
@@ -113,10 +113,16 @@ type JavadocProperties struct {
}
type ApiToCheck struct {
+ // path to the API txt file that the new API extracted from source code is checked
+ // against. The path can be local to the module or from other module (via :module syntax).
Api_file *string
+ // path to the API txt file that the new @removed API extractd from source code is
+ // checked against. The path can be local to the module or from other module (via
+ // :module syntax).
Removed_api_file *string
+ // Arguments to the apicheck tool.
Args *string
}
@@ -729,9 +735,9 @@ func (d *Droiddoc) GenerateAndroidBuildActions(ctx android.ModuleContext) {
`To make these errors go away, you have two choices:\n`+
` 1. You can add '@hide' javadoc comments to the methods, etc. listed in the\n`+
` errors above.\n\n`+
- ` 2. You can update current.txt by executing the following command:`+
+ ` 2. You can update current.txt by executing the following command:\n`+
` make %s-update-current-api\n\n`+
- ` To submit the revised current.txt to the main Android repository,`+
+ ` To submit the revised current.txt to the main Android repository,\n`+
` you will need approval.\n`+
`******************************\n`, ctx.ModuleName()),
},