Fix osx compilation