xcode 10.2.1“体系结构arm64的未定义符号”

时间:2019-05-20 03:08:34

标签: ios swift build cocos2d-x

我有一个在我的PC上用cocos2d-x 3.15创建的游戏,它运行正常。然后,我将项目移至Mac,将平台切换至iOS,并尝试为iOS 9.0和iphone XR设备构建它,现在几天来我都收到错误消息“体系结构arm64的未定义符号”。错误日志是这样的:

"_UIApplicationMain", referenced from:
      _main in main.o
  "_OBJC_METACLASS_$_UIViewController", referenced from:
      _OBJC_METACLASS_$_RootViewController in RootViewController.o
  "_OBJC_CLASS_$_UIViewController", referenced from:
      _OBJC_CLASS_$_RootViewController in RootViewController.o
  "CocosDenshion::SimpleAudioEngine::getInstance()", referenced from:
      TRMusicSound::isMusicPlay() in TRMusicSound.o
      TRMusicSound::loadingGameMusic() in TRMusicSound.o
      TRMusicSound::loadingGameSound(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) in TRMusicSound.o
      TRMusicSound::setMusicStutas(bool) in TRMusicSound.o
      TRMusicSound::playHeadMusic() in TRMusicSound.o
      TRMusicSound::playGameMusic() in TRMusicSound.o
      TRMusicSound::playGetReadySound() in TRMusicSound.o
      ...
  "cocos2d::Node::init()", referenced from:
      vtable for BaseNode in BaseNode.o
  "cocos2d::ui::Widget::addTouchEventListener(std::__1::function<void (cocos2d::Ref*, cocos2d::ui::Widget::TouchEventType)> const&)", referenced from:
      BaseNode::resetWidgetTouchEvent(char const*) in BaseNode.o
  "cocos2d::Vec2::ZERO", referenced from:
      BaseNode::init(cocos2d::Node*, bool) in BaseNode.o
      BaseLayer::LoadUIFile(char const*, bool) in BaseLayer.o
  "cocos2d::CSLoader::createNode(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)", referenced from:
      BaseNode::create(char const*, bool) in BaseNode.o
  "cocos2d::ui::Button::loadTextureDisabled(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, cocos2d::ui::Widget::TextureResType)", referenced from:
      UIGameLayer::updateQetButton() in UIGameLayer.o
  "cocos2d::ui::LoadingBar::setPercent(float)", referenced from:
      UIGameLayer::updateRoleBlood() in UIGameLayer.o
      UIGameLayer::updateRoleMagic() in UIGameLayer.o
      UIGameLayer::setBossBlood(float) in UIGameLayer.o
      UIGameLayer::setBossBlood(float)::$_1::operator()() const in UIGameLayer.o
  "cocos2d::ProgressTimer::create(cocos2d::Sprite*)", referenced from:
      UIGameLayer::initBossCD() in UIGameLayer.o
  "cocos2d::ProgressTimer::setType(cocos2d::ProgressTimer::Type)", referenced from:
      UIGameLayer::initBossCD() in UIGameLayer.o
  "cocos2d::ui::PageView::setCurrentPageIndex(long)", referenced from:
      UISelectScene::updateRolePage() in UISelectScene.o
  "cocos2d::ui::Button::loadTexturePressed(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, cocos2d::ui::Widget::TextureResType)", referenced from:
      UISelectScene::updateButtonStutas(cocos2d::Node*, int) in UISelectScene.o
      UIGameLayer::initHead() in UIGameLayer.o
      UIGameLayer::updateQetButton() in UIGameLayer.o
  "typeinfo for cocos2d::ui::TextBMFont", referenced from:
      UISelectScene::updateCoins() in UISelectScene.o
      UIGameLayer::initPropCount() in UIGameLayer.o
      UIGameLayer::initCombo() in UIGameLayer.o
      UIGameLayer::updateDistance() in UIGameLayer.o
      UIShopLayer::updateCoins() in UIShopLayer.o
      UIResultLayer::initLayerUI() in UIResultLayer.o
.....

我到处搜索,并尝试了一切可能的尝试,但仍然没有运气。到目前为止,我已经尝试过:

  1. 不断变化的架构(armv7和arm64以及标准架构)
  2. 将“仅构建活动架构”更改为否
  3. 将“死代码剥离”更改为否
  4. 将$(继承)添加到“其他链接器标志”
  5. 添加“安全”和“系统配置”框架以建立阶段
  6. 禁用“位码”并启用“保留专用外部符号”

0 个答案:

没有答案
相关问题