debuginfo: Don't create debuginfo for statics inlined from other crates.

Fixes issue #13213, that is linker errors when the inlined static has been optimized out of the exporting crate.