In a wide pan, heat up a little oil, and roast garlic cloves, black peppercorns, cloves, cinnamon stick, mace, and red chillies, till the garlic cloves change color, turning light red.
Then add in the chopped onions and salt, and saute on medium flame till the onions turn golden brown.
While you saute onions, in another pan - dry roast the dry coconut powder till it is well roasted to a reddish color.
Once the onions are done, add in the chopped tomatoes and red chilli powder, and saute for 2-3 minutes till everything is mixed well.
Then mix in the roasted coconut powder, turn off the heat, and set aside for 15-20 minutes, till the roasted items cool off a bit.
Finally, in a mixie - blend the roasted onion-tomato-spice mix with fresh water to form a smooth paste.