CVS, Walgreens finalize $10B in settlements over opioids