Interaction between externalNativeBuild and project.buildDir

149 views
Skip to first unread message

Joe Bowbeer

unread,
Nov 14, 2016, 9:54:41 PM11/14/16
to adt-dev
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?


Piasy Xu

unread,
Oct 15, 2018, 11:56:12 PM10/15/18
to adt-dev
You can delete the .externalNativeBuild dir, then run generateJsonModelDebug or generateJsonModelRelease, it will recreate the .externalNativeBuild dir.

在 2016年11月15日星期二 UTC+8上午10:54:41,Joe Bowbeer写道:
Reply all
Reply to author
Forward
0 new messages