The proverb you can’t have your cake and eat it (too) means you can’t enjoy both of two desirable but mutually exclusive alternatives.
It made more sense in its early formulations, when the positions of have and eat had not been reversed. It is first recorded in A dialogue conteinyng the nomber in effect of all the prouerbes in the englishe tongue compacte in a matter concernyng two maner of mariages (1546), by the English playwright and epigrammatist John Heywood (circa 1496-circa 1578); a husband is told the following by his wife:
What man, I trowe [= believe] ye raue.
Wolde ye bothe eate your cake, and haue your cake?
The formulation is even clearer in The Scourge of Folly. Consisting of satyricall Epigramms, and others in honor of many noble and worthy Persons of our Land. Together, With a pleasant (though discordant) Descant vpon most English Prouerbes: and others (1611?), by the English poet and writing master John Davies ‘of Hereford’ (1565?-1618):
‘A man cannot eat his cake and haue it stil:’
That may he, vnlesse his retention be ill.
The French equivalent of this proverb is on ne peut pas avoir le beurre et l’argent du beurre, meaning you can’t have the butter and the money’s worth of the butter.
An expanded form is on ne peut pas avoir le beurre, l’argent du beurre et le sourire de la crémière (or de la fermière) (par-dessus le marché), the last part meaning and the smile of the milkmaid (or of the woman farmer) (into the bargain), the word sourire being sometimes replaced by cul, arse.