Try setting the CC_aarch64-unknown-linux-gnu env var to the name of the C cross compiler for the target when running cargo. I think it is trying to use the host C compiler and then failing to find libc headers for the host. A cross compiler should look for libc headers for the target which are correctly installed.