Look into Leon's thread:
http://outskirts.altervista.org/forum/viewtopic.php?f=40&p=21364#p21364
About here is the important part:
_______________
If it's give you fatal error (like it most of time it's gives me)header missing like <fstream> , <istream>
its because std ib++ is not loaded in main memory, you have to first build using "clang" and built-in cross compiler "aarch64-linux-android-clang++" after that remove that build (because its useless without ndk) and run again the NDK build command. This just my theory I am not 100% sure why it's actually happened but my trick works.
_______________
But I never had this problem in Droidfish since in my Droidfish
std lib++ is installed and everything compiled in Termux always also worked in Droidfish. Maybe you have to wait for Archimedes, he knows what to do