Fixes to clean undefined behavior (see ROOT-6710) detected by running all the tests and tutorials with gcc4.9.0 and -fsanitize=undefined
Use a stamp file control copying files (avoids unneeded actions when using Ninja). Test stressGoFTest requires mathmore.