Drugmaker Mylan said a settlement would allow it to launch a generic version of the drug as early as December 2017.