labial and/or velar continuant (approximant or fricative) or [h]
open and/or rounded vowel
labial and/or velar continuant or a close back rounded vowel
Exceptions are relatively easy to explain:
What’s being transliterated as Farsi “gh” is likely “غ”. It’s [ɢ]~[ɣ]. It is not an actual exception.
Russian used to have a [ɣ] sound, but it got merged into /g/. (Note this explains why some older loanwords with /h/ get neared to /g/, [h] and [ɣ] sound somewhat similar.)
Spanish gu- is [gʷ], a sound Romance languages often use as replacement for [w], after Latin [w] became [v]. Spanish did redevelop the sound but odds are the onomatopoeia is older.
General pattern seems to be:
Exceptions are relatively easy to explain: