The point of having taxes is for government to extract money from companies that collect lots of money from their clients. If you are using technicalities of the system to go against this goal you are only as bad as a hacker that uses technicalities of system you built and maintain to get access to things that were supposed to be protected.
Don't get me wrong. I don't see nothing intrinsically wrong in using law or any other system to full extent. What makes it wrong or not are additional circumstances. Evading taxes in badly managed country to fund basic research or education is much less bad than putting this money right in the pockets of various wealthy people so they can buy yahts.
If everyone, including small businesses, got to pay 0% tax, then you might have a good argument. But as it stands, we have a 35% corporate tax rate for everyone except large multi-national companies who have the means to take advantage of the loopholes. Regular Joe Business does not have those means.
And of course, these same large companies are spending millions lobbying the government to not reform the code.
I don't know why so many people think Apple pays little or no tax. They are in fact the 3rd largest income tax payer in the US.
[1] http://finance.yahoo.com/news/companies-paying-most-taxes-17...
The companies that get squeezed are not the Regular Joe Businesses but the midsize businesses that can't get away with paying out all profits as salary (because they have third party shareholders who don't work for the business) and yet can't afford to set up the necessary bureaucracy to take advantage of things like a Double Irish With a Dutch Sandwich.
How did you arrive at this (normative) judgement? They are paying the minimum in taxes that they legally can, so that they can invest the money in research, buy back stocks, or hold it in reserve for some period of time; why is this bad? Do you have any evidence that the government's allocation of additional funds would be more productive than Apple's use of the money?