Three things to consider.
1) Bosh is not an unfair comp to KG on offense. Through their
respective age-29 seasons, KG was slightly better by the numbers, but he also was the only guy carrying his team on both sides of the ball. KG was +2 RB, +2 AST, but they have the same per-36 scoring. Not saying Bosh=KG, but he's definitely worth a max deal, and will probably be a very good player at the end of the deal.
2) Assuming this isn't a max 35% contract, but is instead fixed at max for 2014-15 with standard 4.5% risers, it probably shouldn't be a big worry. The cap is going to grow faster than 4.5% over the next 4 years to the point that 24M isn't prohibitive.
3) The amount of salary pressure this puts on Miami is huge.
In other words, I think this is exactly what a sabermetrically-savvy team might do, especially if it plans to clear Lin's contract.