Weed out uses of `system`

This patch replaces uses of `system` with `rawSystem`, correcting handling of whitespace and shell-interpreted characters in filenames, and blocking possible vectors for shell injection (fixes #1697). To do this, it replaces all instances of command-line fragment strings with argument lists. This also means that it is no longer possible to stuff multiple flags into one `%flag` directive, as one test did.