Fix compilation on OSX 10.10
Closes #1646
Merge pull request #1652 from tobbi/fix_mac_compilation

Fix compilation on OSX 10.10