Process for the preparation of thiazolopyrimidines