Fix run-pass/lang-item-public test on FreeBSD
auto merge of #17972 : ebfe/rust/rpass-lang-item, r=alexcrichton