The definition of profit is the excess of revenue over costs. The underlying activity that produces the revenue, and incurs the cost, can be almost anything.
As Robert Nozick pointed out in his 1974 article “Why Intellectuals Oppose Capitalism,” intellectuals find this lack of definition in the goals and reward structure of capitalism frustrating. After all, intellectuals have spent their lives going to the best schools, getting the best grades, and congratulating each other on being the most important members of society.