Luckily, they supplied the source code and I then modified it to remove all NSIS-related things. I also removed some of the other code that reports errors, and slightly altered the exported functions.
All hail open source!
To run it, you just use the
untgz(char *path_to_tgz_file, char *output_directory);