Add platform detection for openbsd & freebsd compatibility

Just uses gmake instead of make if the OS platform ends with bsd.