fix OS X-targeted compilation issue