The defense ministry said it would only pursue ‘nongovernmental’ ties with Taipei.