Compilation: add missing link file options to cache manifest
I unintentionally closed #23891 while pruning branches; this is the exact same diff.
Resolves: #23869
I'll take that, I certainly don't think it can cause any issues. I'll try and double check that it actually fixes the issue (I barely tested this locally lol) and merge if all is well.
Rebased, and tested the -fentry case locally -- and at that point I had pretty much written a standalone test case anyway, so I added that in. The test is confirmed as failing on master and passing on this PR.
-fentry is either broken on our Mach-O linker or requires something special, so I've just hardcoded the standalone test target to x86_64-linux, since I know it works there. That's fine, since we're mainly trying to test the frontend there, and in particular the caching mechanism.