Remove the stems and seeds of the peppers. Bake the peppers on a metal sheet or grill. Peel the skins. Don't wash them after that. Carefully remove any remaining seeds, if present. Put all of the peppers in a large tray, set it aside.
Bake the eggplants in the oven, in a tray next to each other. Once baked, peel them. Remove the stems and peels. Chop the eggplants into coarse pieces.
Wash jars and caps. Dry them well.
Arrange a layer of eggplants, layer of peppers.
Clean the garlic, put cloves of it between the layers.
Make a marinade in another container by mixing the vinegar, sugar and salt. Stir. Pour the marinade into the jars.
Close the jars well with caps. Sterilize for 15 min. after the water comes to a boil.