code cleanup
fix for #737 to build script
Merge pull request #787 from waterbearlang/737_only_include_existing_files

737 only include existing files