1. Move to a jurisdiction with zero tax or territorial taxation laws you can use in your favour.
2. Advanced corporate structures which will normally minimize - not completely avoid - taxes. Speak to a lawyer or qualified accountant about how to set this up, if it's even viable for your company and situation.