Porphyrin- and phthalocyanine-based systems for rechargeable batteries