Fixed compilation issues in mavericks.