MySQL: allow compilation with Xcode-only setups

Closes #20185.