Profits in the long run under perfect competition

This, of course, has a very important implication for the firm’s profits.
Why is it that perfectly competitive firms cannot make economic profit in the long run? What eliminates short run profits under perfect competition