Teva Pharmaceutical Industries Ltd., a Tel Aviv, Israel-based manufacturer of generic opiates, has agreed to a $4.25 billion global settlement to resolve thousands of lawsuits.

The global deal, announced as part of Teva’s quarterly earnings on Tuesday, would provide $3.7 billion to states, local communities and Native American tribes, plus $1.2 billion worth of generic Narcan, a nasal spray used to treat opioid overdoses. The deal is contingent on reaching an indemnification agreement with another generic opioid manufacturer, Allergan, and on Allergan, which is part of AbbVie, reaching its own nationwide settlement, as well as the participation of a certain number of states, subdivisions and Native American tribes.