Merge pull request #859 from skaes/master

Problem: make debug does not work on OS X