I've been transitioning to the externalNativeBuild support in the stable gradle plugin.
I've noticed that command lines for ndkBuild are cached in a hidden, ignored .externalNativeBuild folder that is not
in the project's build folder.
This has been reported here: Issue 222274
This is causing problems for me because I'm redefining project.buildDir.
AFAICT, neither .externalNativeBuild nor its contents are removed by gradle clean, and the command files in .externalNativeBuild are not being regenerated when the project.buildDir changes. This is causing values to be used for NDK_OUT and NDK_LIBS_OUT that do not correspond to the current project.buildDir.
Is there some way in build.gradle to force externalNativeBuild to use the current project.buildDir?