Loading ravenwood/tools/ravenizer/src/com/android/platform/test/ravenwood/ravenizer/Ravenizer.kt +1 −1 Original line number Diff line number Diff line Loading @@ -127,7 +127,7 @@ class Ravenizer(val options: RavenizerOptions) { } } stats.totalProcessTime = log.iTime("$executableName processing $inJar") { stats.totalProcessTime = log.vTime("$executableName processing $inJar") { ZipFile(inJar).use { inZip -> val inEntries = inZip.entries() Loading ravenwood/tools/ravenizer/src/com/android/platform/test/ravenwood/ravenizer/RavenizerOptions.kt +23 −2 Original line number Diff line number Diff line Loading @@ -20,6 +20,20 @@ import com.android.hoststubgen.ArgumentsException import com.android.hoststubgen.SetOnce import com.android.hoststubgen.ensureFileExists import com.android.hoststubgen.log import java.nio.file.Paths import kotlin.io.path.exists /** * If this file exits, we also read options from it. This is "unsafe" because it could break * incremental builds, if it sets any flag that affects the output file. * (however, for now, there's no such options.) * * For example, to enable verbose logging, do `echo '-v' > ~/.raveniezr-unsafe` * * (but even the content of this file changes, soong won't rerun the command, so you need to * remove the output first and then do a build again.) */ private val RAVENIZER_DOTFILE = System.getenv("HOME") + "/.raveniezr-unsafe" class RavenizerOptions( /** Input jar file*/ Loading @@ -35,9 +49,16 @@ class RavenizerOptions( var fatalValidation: SetOnce<Boolean> = SetOnce(false), ) { companion object { fun parseArgs(args: Array<String>): RavenizerOptions { fun parseArgs(origArgs: Array<String>): RavenizerOptions { val args = origArgs.toMutableList() if (Paths.get(RAVENIZER_DOTFILE).exists()) { log.i("Reading options from $RAVENIZER_DOTFILE") args.add(0, "@$RAVENIZER_DOTFILE") } val ret = RavenizerOptions() val ai = ArgIterator.withAtFiles(args) val ai = ArgIterator.withAtFiles(args.toTypedArray()) while (true) { val arg = ai.nextArgOptional() Loading ravenwood/tools/ravenizer/src/com/android/platform/test/ravenwood/ravenizer/adapter/RunnerRewritingAdapter.kt +2 −2 Original line number Diff line number Diff line Loading @@ -184,7 +184,7 @@ class RunnerRewritingAdapter private constructor( av.visit("value", ravenwoodTestRunnerType.type) av.visitEnd() } log.i("Update the @RunWith: ${classInternalName.toHumanReadableClassName()}") log.v("Update the @RunWith: ${classInternalName.toHumanReadableClassName()}") } /* Loading Loading @@ -442,7 +442,7 @@ class RunnerRewritingAdapter private constructor( // Don't process a class if it has a @NoRavenizer annotation. classes.findClass(className)?.let { cn -> if (cn.findAnyAnnotation(noRavenizerAnotType.descAsSet) != null) { log.w("Class ${className.toHumanReadableClassName()} has" + log.i("Class ${className.toHumanReadableClassName()} has" + " @${noRavenizerAnotType.humanReadableName}. Skipping." ) return false Loading Loading
ravenwood/tools/ravenizer/src/com/android/platform/test/ravenwood/ravenizer/Ravenizer.kt +1 −1 Original line number Diff line number Diff line Loading @@ -127,7 +127,7 @@ class Ravenizer(val options: RavenizerOptions) { } } stats.totalProcessTime = log.iTime("$executableName processing $inJar") { stats.totalProcessTime = log.vTime("$executableName processing $inJar") { ZipFile(inJar).use { inZip -> val inEntries = inZip.entries() Loading
ravenwood/tools/ravenizer/src/com/android/platform/test/ravenwood/ravenizer/RavenizerOptions.kt +23 −2 Original line number Diff line number Diff line Loading @@ -20,6 +20,20 @@ import com.android.hoststubgen.ArgumentsException import com.android.hoststubgen.SetOnce import com.android.hoststubgen.ensureFileExists import com.android.hoststubgen.log import java.nio.file.Paths import kotlin.io.path.exists /** * If this file exits, we also read options from it. This is "unsafe" because it could break * incremental builds, if it sets any flag that affects the output file. * (however, for now, there's no such options.) * * For example, to enable verbose logging, do `echo '-v' > ~/.raveniezr-unsafe` * * (but even the content of this file changes, soong won't rerun the command, so you need to * remove the output first and then do a build again.) */ private val RAVENIZER_DOTFILE = System.getenv("HOME") + "/.raveniezr-unsafe" class RavenizerOptions( /** Input jar file*/ Loading @@ -35,9 +49,16 @@ class RavenizerOptions( var fatalValidation: SetOnce<Boolean> = SetOnce(false), ) { companion object { fun parseArgs(args: Array<String>): RavenizerOptions { fun parseArgs(origArgs: Array<String>): RavenizerOptions { val args = origArgs.toMutableList() if (Paths.get(RAVENIZER_DOTFILE).exists()) { log.i("Reading options from $RAVENIZER_DOTFILE") args.add(0, "@$RAVENIZER_DOTFILE") } val ret = RavenizerOptions() val ai = ArgIterator.withAtFiles(args) val ai = ArgIterator.withAtFiles(args.toTypedArray()) while (true) { val arg = ai.nextArgOptional() Loading
ravenwood/tools/ravenizer/src/com/android/platform/test/ravenwood/ravenizer/adapter/RunnerRewritingAdapter.kt +2 −2 Original line number Diff line number Diff line Loading @@ -184,7 +184,7 @@ class RunnerRewritingAdapter private constructor( av.visit("value", ravenwoodTestRunnerType.type) av.visitEnd() } log.i("Update the @RunWith: ${classInternalName.toHumanReadableClassName()}") log.v("Update the @RunWith: ${classInternalName.toHumanReadableClassName()}") } /* Loading Loading @@ -442,7 +442,7 @@ class RunnerRewritingAdapter private constructor( // Don't process a class if it has a @NoRavenizer annotation. classes.findClass(className)?.let { cn -> if (cn.findAnyAnnotation(noRavenizerAnotType.descAsSet) != null) { log.w("Class ${className.toHumanReadableClassName()} has" + log.i("Class ${className.toHumanReadableClassName()} has" + " @${noRavenizerAnotType.humanReadableName}. Skipping." ) return false Loading