Fix cabal compile error under mac osx , should improve the mac osx performance