fix #167, make option ncpus work in linux.
Merge pull request #168 from zorksylar/fix-ncpus-bug

fix #167, make option ncpus work in linux.