This may not be the solution for everyone but the answer comes down to how cross compilation and linking works. What I am attempting to do here is create a static binary, there are two commands that can be used:
RUSTFLAGS="-Ctarget-feature=-crt-static"
- dynamic linking of the c runtime.
RUSTFLAGS="-Ctarget-feature=+crt-static"
- fully static compilation of C runtime.
There is also a separate issue here, the use of openssl-dev
- this requires glibc to compile by default, you need to set this up to be compiled statically. I haven't got to the bottom of this yet but the three solutions I have found (2 work, 1 I haven't tried yet).
I am planning on writing a medium article where I added all my problems and findings, just think it might help others when I post this.