Add auto-thread calculation for buildscript.

Get the number of processors, and add one more thread for building.