Fame and respect are not mutually exclusive.
You can be famous but behave in ways to earn or command respect.
Similarly you can become so respected that some measure of fame is produced.
But if you look at these two terms as destinations rather than attributes, then it becomes obvious who is chasing what.
The formula for fame is simple: Get attention. Do it however you can.
The formula for respect is likewise simple: Do great and meaningful work. Have integrity.
I hope to have some measure of both fame and respect. But I’ll trade fame for respect any day.