Unix build script, fixed build on unix

closes #9