Still, I think we should build a moon base for the same reason we should go to Mars: even if these projects don't yield direct benefits, they are probably necessary steps to exploring the solar system and beyond.
In terms of your "why explore space at all while children are dying in Africa?" argument -- we can do multiple things at once! Anyway, people's interests aren't fungible: you can't force the people who want to dedicate their lives to exploring space to instead dedicate their lives to curing malaria. Even if you could, people should be allowed to do what they like. And complaining that person X is doing prosocial activity A rather than prosocial activity B is stupid and antisocial.