sage: integrate(abs(sin(x)),x)

Not that this is all that useful, because if we call this f then f(pi) has division by zero error, and based on comments elsewhere it is probably wrong in any case. I have to admit I am surprised this isn't doable, though. See this ticket 17511 but there are lots of places this question has recurred.