Heat the oil in a lidded kadhai or wok over a medium heat. Fry the garlic for 1 minute. Add the curry leaves and the masala paste, and fry for 5 minutes, stirring. Add the sugar and stir until it dissolves. Add the drained aubergine and the chilli powder, and stir well. Season and fry for 4-5 minutes. Turn the heat down and simmer with a lid on for 20-25 minutes, stirring halfway, until the aubergine has cooked through and oil rises to the surface. Cool and decant into a sterilised jar. Chill for a week before opening.