Unless anyone can convince me of otherwise, I’ve given up on cmake being able to cross-compile on Linux from x64 to aarch64.
I started this topic about it earlier on a C group:
https://groups.google.com/forum/#!topic/comp.lang.c/B9msZxHI-as
I think tomorrow I will take the CMakeLists.txt files, generate GNU Makefiles from them, and then dismantle the GNU Makefiles so that I have simple one-liner commands like:
aarch64-linux-gnu-gcc -o interface.o -c interface.c
aarch64-linux-gnu-gcc -o computation.o -c computation.c
aarch64-linux-gnu-gcc -o calculator interface.o computation.o
Then I’ll just collect all these one-liner commands together and put them in a script, “make.sh”.
I even tried editing the cmake source code for “try_compile” in order to try get rid of the error about not being able to find an intermediary executable file, but I didn’t get anywhere.
I haven’t heard of anyone successfully cross-compiling with cmake on Linux from x64 to aarch64.