Set external linkage on Rust functions defined with foreign ABIs.

This fixes an issue where `extern "C"` functions would have internal linkage, making them invisible to anything that might be linked against the resulting object. In my use case, a Rust function is being called from assembly, and because the Rust symbol did not have the right linkage, I ran into linker errors.

I'm not sure where to put tests for this particular change as there don't seem to be any as it stands for `extern "C"` functions. A `make check` passes, so this does not seem to have broken anything that is already covered. Also, a test would need to inspect the symbol linkage in the binary output (or bitcode?) in order to figure out if this is working as expected. I'm not sure how best to do that in a portable way.