In my wiki page for MH on Pi based upon raspbian I have this.

aptitude install libgd-gd2-perl libgd-text-perl
Re
 Sean M