yeah, the more hairy the less ability to shed heat, that would have been a survival pressure causing death by sunstroke
also, less, but still hairy, has a benefit of wicking sweat away faster as it is only cooling if it gets cooler fast enough
there isn't many animals that sweat, i think pigs are another one, also note that the domestic pig is also with very high fat content and domesticated pigs are less hairy than wild boars
so probably, humans breeding pigs for the good fat levels also forced the animals to grow less hair, and thus also they sweat