Add linuxbld.sh script for building on Linux, plus code cleanup