What specifically are you trying to do? For things like AC3 or DTS to WAV/MP3/AAC, there are likely simpler command-line solutions than trying to reproduce exactly what AutoGK does. For example, when transcoding 5.1 AC3 to MP3, one could decode the AC3 data and downmix to stereo with eac3to and either pipe or use a WAV intermediate file to pass the data to LAME with whatever settings one wished.