fixing OSX build

see #cde10602a6e4cfbf10126ea9bcefb6b79175818b