The Second Macedonian War in 202 BCE was between Macedonia and Rome. Philip V of Macedonia began laying siege to the Greek city-states in the Aegean, having formed an alliance with Antiochus III of the Seleucid Empire. Both Philip V and Antiochus III were keen to expand their empires and had already come to an agreement to share conquered territories, with a divided Egypt their main target. The Greek Aegean islands were being harried by Philip and, terrified of being annexed by the combined forces of Philip V and the Seleucid Empire, appealed to Rome for help. Rome responded, despite years of apathy towards Greece, by threatening Philip with war if he continued with his designs on these small, independent states. He refused and was defeated by a Greek-Roman army at the Battle of Cynoscephalae (197 BCE). Following this, the Aetolian and Achaean Leagues (Greek confederacies) formed alliances with Rome.