The evolution of primary sexual characters in animals