Who would win between a boxer and an MMA fighter?

In a fight with virtually no rules, or with rules that are followed in MMA. The MMA fighter will clearly have the advantage over the boxer, because MMA fighters have a wide variety of skills, for instance they can use both their hands and legs. However, under boxing rules, the same principle will apply, a boxer would definitely have the upper hand in this setting. A good example is the Floyd Mayweather vs Conor McGregor fight, which was under boxing rules and saw mayweather emerge as the winner.