The leaders of South and North Korea agreed Thursday to denuclearize the Korean peninsula, end military hostility and establish a permanent peace treaty to replace the armistice which ended the 1950-53 Korean War during the second inter-Korean summit, DPA quoted Yonhap news agency as reporting. South Korean President Roh Moo Hyun and North Korean leader Kim Jong Il Thursday signed an eight-point joint declaration at the conclusion of an historic three-day summit in Pyongyang. The two Koreas are still technically at war more than 50 years after the conflict ended with an armistice and not a peace treaty. The declaration calls for a four-party summit that would involve the United States and China, which fought alongside South and North Korea in the war respectively, and are signatories to the armistice. A previous attempt to reach a peace in 1999 between the four nations ended without any result. The joint declaration also includes an agreement to hold inter-Korean prime ministerial talks in Seoul in November to discuss details of the agreements, including to co-operate to create a nuclear weapon-free Korean peninsula. "The South and the North closely co-operate in order to terminate military hostilities, ease tension and ensure peace on the Korean peninsula," said the declaration signed by the two Korean leaders. South and North Korea also agreed on joint efforts to support six-party talks on the North's denuclearization, the first time the reclusive Kim has personally committed to ending the North's nuclear weapons programme. On Wednesday, North Korea agreed to disable key nuclear facilities by the end of this year, according to a joint statement issued by China on behalf of six nations participating in the talks. The statement followed talks last week between North Korea, the United States, China, South Korea, Russia and Japan aimed at negotiating an end to North Korea's nuclear programme. A special peace zone in the disputed Yellow Sea, which has seen repeated clashes between warships from the North and South, was also part of the declaration. North Korea does not recognize the maritime border line, drawn unilaterally by the United Nations at the end of the Korea War, and demands that it be redrawn further south. On Thursday, the two countries also agreed to open a cross-border cargo railway. In a test in May, trains crossed the heavily fortified border between North and South Korea for the first time in 56 years. The rail link, considered one of the most important projects of inter-Korean rapprochement in recent years, has since lain dormant. The South Korean Olympic cheering squad will also be allowed to use the railway through North Korea to reach Beijing next year for the 2008 Olympic Games. The first inter-Korean summit was held in June 2000 between former South Korean president Kim Dae Jung and the North Korean leader.