Use command-line parsing in apiUsageSample
Extend build_r8lib.py so that it also runs the R8 command-line through
the API usage sample after linking with the minified r8lib.jar. This
ensures that we keep a large enough portion of the R8 API so that a user
could reimplement the R8 command-line.
Regenerate d8_api_usage_sample.jar and r8_api_usage_sample.jar by
running tools/gradle.py buildApiSampleJars.
Change-Id: I2342b395e07f2f9b6245ae746f47973948c39d57
diff --git a/build.gradle b/build.gradle
index cd831cc..f379bbf 100644
--- a/build.gradle
+++ b/build.gradle
@@ -111,7 +111,12 @@
}
apiUsageSample {
java {
- srcDirs = ['src/test/apiUsageSample']
+ srcDirs = ['src/test/apiUsageSample', 'src/main/java']
+ include 'com/android/tools/apiusagesample/*.java'
+ include 'com/android/tools/r8/BaseCompilerCommandParser.java'
+ include 'com/android/tools/r8/D8CommandParser.java'
+ include 'com/android/tools/r8/R8CommandParser.java'
+ include 'com/android/tools/r8/utils/FlagFile.java'
}
}
debugTestResources {