from carboxylic acids, their anhydrides, esters or halides