They broke the law indeed. It was a legally untested tax structure that was found to be illegal all along. This also is not the first time the European courts have told member states to stop preferential treatment in tax deals.
It's funny that you say it was well known to everyone and also wasn't an issue. It was well known because precisely because it was an issue.
If a company and country are dishonest about the tax deals they illegally make it's pretty dishonest to call it dishonest to demand the taxes are back payed.
This ruling applies to all the illegal tax schemes European countries have been using. So there are definitely other companies getting the bill as well.
It wasn't even well known until very late into the 2000s (even early 2010) when Apple actually started to make a lot of money and got a lot more scrutiny.
Because it is pretty simple, you don't really care about a struggling company or one that just gets by, even if their marginal tax rate is lower than it is supposed to be, since there isn't much to be taxed the difference is minimal in any case.
However, if the company is extremely successful and makes big money the difference is absurd and it actually becomes unfair for everyone (both other companies who have to play by the rules, and citizens who get taxed more than a filthy rich corp).
And this is the real reason it "became" a problem and took a while to resolve. Had Apple stayed a relatively small company with small sales numbers in the EU (and thus small profits) the deal would have probably not have much scrutiny and even if it had, it probably wouldn't have gotten any focus.
It would have cost more money in legislators time than it would have brought in anyway, even though the deal was fundamentally unfair. But life is generally unfair, so it doesn't matter that much.
It's funny that you say it was well known to everyone and also wasn't an issue. It was well known because precisely because it was an issue.
If a company and country are dishonest about the tax deals they illegally make it's pretty dishonest to call it dishonest to demand the taxes are back payed.
This ruling applies to all the illegal tax schemes European countries have been using. So there are definitely other companies getting the bill as well.