AMSTERDAM (Reuters) - The International Court of Justice (ICJ) on Friday said it has dropped a long-running territorial dispute between Malaysia and Singapore by mutual consent.

The court said Malaysia this week notified it of its intent to drop its claim to Pedra Branca island, near the opening of the Straits of Singapore. After checking with Singapore, the court moved to cancel hearings scheduled for later this month and formally end the dispute.

In a 2008 ruling, the ICJ awarded the Middle Rocks formation to Malaysia while nearby Pedra Branca was given to Singapore. Malaysia last year sought to have the Pedra Branca part of the ruling overturned.

Malaysia’s new prime minister Mahathir Mohamad said Wednesday that his government planned to enlarge the Middle Rocks to form a small island.

Singapore was once part of Malaysia but they separated acrimoniously in 1965, clouding diplomatic and economic dealings for years.

Some of the frostiest years were during Mahathir’s previous tenure as prime minister between 1981 and 2003.