There is a small mistake in Host.cpp line 305, should be:
#ifdef PLATFORM_FREEBSD
Is there a reason to stick to bash shell in line 217?
If not, we should call 'sh' instead, since each POSIX system has its own default shell, but they all should have 'sh' installed.