Add quotes, fix build system

Linux (and probably OSX, as they use the same shells) will have issues with this if variables are improperly quoted.