Fix build on OpenSolaris.

With these changes, dmd compiles on OpenSolaris 11.1.