Prime Minister Shinzo Abe and Philippine President Rodrigo Duterte agreed Friday that a U.S. commitment to the Asia-Pacific is needed to ensure peace and prosperity in the region as uncertainty lingers over President-elect Donald Trump’s foreign policy agenda.

Meeting for the second day in Duterte’s hometown of Davao in the southern Philippines, the two leaders also touched on the issue of China’s military buildup in the South China Sea and vowed to resolve disputes under the rule of law, the Japanese Foreign Ministry said.

The Philippines has conflicting claims with China in the disputed waters, along with four other countries.

Duterte told Abe he is ready to have direct talks with China concerning the South China Sea, according to the ministry. Duterte has previously suggested setting aside the territorial dispute with Beijing in favor of boosting economic cooperation with the world’s second-largest economy.

Abe hopes the Philippines and China adhere to a ruling last July by a United Nations-backed tribunal in The Hague, which concluded that China’s claim over almost the entire South China Sea has no legal basis.

China has not accepted the decision over the case brought by Duterte’s predecessor, Benigno Aquino.

With the Philippines assuming the chairmanship of the 10-member Association of Southeast Asian Nations for 2017, Abe said in the talks with Duterte that he hoped to coordinate with Manila on stressing the principle of the rule of law at a series of ASEAN-related meetings, which culminate with a summit also involving leaders from the U.S., Japan and China, the ministry said.

Duterte reacted angrily last year when the administration of U.S. President Barack Obama aired concerns about extrajudicial killings in Duterte’s anti-drugs campaign.

However, on Friday Abe and Duterte shared the view that a continued U.S. commitment to the Asia-Pacific region is needed. Duterte vowed to continue his country’s cooperation with the U.S. under a bilateral alliance, according to the ministry.

Trump, who has suggested a shift to a protectionist trade policy and a more muscular foreign policy, will take office on Jan. 20.

Earlier Friday, the leaders held informal talks over breakfast at Duterte’s private residence in Davao on the island of Mindanao, where the Philippine president has spent around half of each week even after taking office last June.

It is the first visit by a sitting foreign leader to Davao, where Duterte served as mayor for around 22 years and enjoys a more than 90 percent approval rating.

On Thursday in Manila, the leaders agreed on economic and security cooperation amid China’s growing assertiveness in the region. Abe also pledged a public-private aid package of ¥1 trillion to spur infrastructure development in the fast-growing Southeast Asian country, including for promoting agricultural businesses in Mindanao.

Davao is home to many Filipinos of Japanese descent and has received Japanese-funded development projects, according to Japanese officials. Japan also has a consular office there.

China, meanwhile, is also seeking to increase its presence in the area, saying last October it will open a diplomatic mission in the city.

The Philippines is Abe’s first stop on a six-day overseas trip since Thursday. He will also travel to Australia, Indonesia and Vietnam.

Also Friday, the two leaders attended a ceremony where Abe named a critically endangered Philippines eagle “Sakura,” which means cherry blossom in Japanese.

The bird, also known as the monkey-eating eagle, is endemic to the Philippines and is its national bird.