Fix compile issues on OSX with GCC
Merge pull request #338 from chaubold/carsten_master

Fix compile issues on OSX with GCC