This logic should probably happen in the compiler shims rather than in the main Homebrew process.