Tweak static build without optional libraries