Last time I was careless to updated Android Studio to the latest realease:
Android Studio Arctic Fox | 2020.3.1
Build #AI-203.7717.56.2031.7583922, built on July 27, 2021
Then all the cpp files disappeared in my project navigator in Android session:
I can only see the jni folder and a jni.cpp
file in Project session:
and all other cpp files in cpp
folder missed. I have tried to delete all CMakeCache.txt
files in directory .externalNativeBuild
but it does not work, my gradle is as follows:
externalNativeBuild {
cmake {
path "../../../CMakeLists.txt"
}
}
And the building system still compiles these cpp files. Who can help me out? or should I downgrade to original version?
2
Answers
This answer is not quite answering the exact question, but I found if you want to just show your JNI files again in Android Studio do this –
Create an empty Android_dummy.mk file, then add this to your gradle:
I needed this as I build the libraries outside AS manually with ndk-build
to add CPP folder again.