The salaries for lawyers vary like those for software developers. There are a vast number of grunts doing basic work and making adequate salaries. BUT, towards the top of the pyramid, which is exceptionally difficult to reach, there are those making eye-popping salaries.
Ditto with the IT field. That guy who "stole" code from Goldman Sachs, Sergey Aleynikov, was pulling down 400K a year at Goldman. He was set to get 3 times that amount from another company upon leaving Goldman. That's like an elite lawyer's salary. BUT - some guy doing PHP on a no-benefits contract - what, 50-60K? Some average guy doing intranet programming, or building websites for small businesses as an employee? Probably averaging in the same range, maybe a tad higher.
The difference is that there is no bar to entry for programmers. Lawyers have to pass the bar. Anybody can start slapping together apps or get on a no-benefits contract with a little experience. Plus lawyers are highly organized, with the ABA, the American Trial Lawyers association (representing plaintiff lawyers), etc. IT types are way too... I dunno, disorganized, libertarian, low-social-IQ (in general) for that kind of thing. But people that make businesses are not low social IQ. They're dealmakers. And they absolutely hate having to pay these high salaries. They figure if they can flood the market, they can lower their labor costs.
Jokes on them a bit though. True, they'll suppress IT salaries in general. But the superstars will still be a small fraction of the overall IT pool, and they'll still command the stratospheric, though a bit lower, salaries.
And programmers ought to be organizing more behind the ACM, I guess, and encouraging some kind of "PE" (Professional Engineer) equivalent to mark one as someone who actually knows the theory of computer science and practice of programming.