meson: modify gperf test to remove sh dependency
modifies the gperf test to instead rely on a file input rather than piping in using sh, as sh is often not reliable on Windows due to paths.
Also changes the if else ladder into a foreach loop.
Closes #333 (closed)