Exact barotropic distributions in Einstein-Gauss-Bonnet gravity