【问题标题】:Cordova XCode app build clang error linker command failed on Launch NavigatorCordova XCode app build clang error linker command failed on Launch Navigator
【发布时间】:2016-11-01 06:19:05
【问题描述】:

我正在尝试在使用地理定位和导航插件的 XCode 上构建我的 Cordova 应用程序。当我从 XCode 构建应用程序并将其部署在模拟器上时,它工作正常。但是当我添加使用地理定位和导航插件的代码时,构建失败并出现以下错误:

如何解决?

【问题讨论】:

    标签: ios objective-c xcode cordova


    【解决方案1】:

    如果您有权访问 CMMapLauncher.h 和 CMMapLauncher.m,请尝试将 CMMapAddress 和 CMEmptyBool 重命名为 CMMapAdress1 和 CMEmptyBool1。 该错误表明CMMapLauncher和LaunchNavigator中这两个变量存在重复。

    【讨论】:

    • 我找到了这些文件,但在这些文件中找不到变量 CMMapAddressCMEmptyBool。您能否告诉我您是如何确定这些变量需要从跟踪中重命名的?
    • 对不起,我把变量名复制错了:CMEmptyAdress 和 CMEmptyCoord。
    • 表示:重复符号_CMEmptyAddress在...CMMapLauncher.o和LaunchNavigator.o
    • 我更改了这些,但随后它给出了四个链接器错误,在 LaunchNavigator.h 和 LaunchNavigator.m 中作为对不存在变量的引用,为了修复这些我不得不将它们重命名为 CMEmptyAddress1CMEmptyCoord1,然后在再次构建时,我遇到了与原始问题相同的错误,但现在使用CMEmptyAddress1CMEmptyCoord1。请提出任何替代方案。
    • 这些变量有 2 个声明,一个在 LaunchNavigator.h 中,另一个在 CMMapLauncher.h 中,对吧??
    【解决方案2】:

    将“No Common Blocks”从 Yes 更改为 No(在 Targets->Build Settings->Apple LLVM - Code Generation 下)解决了这个问题。

    来源:https://github.com/dpa99c/phonegap-launch-navigator/issues/92

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2017-11-07
      • 2012-05-15
      • 1970-01-01
      • 2013-01-01
      • 2019-07-20
      • 2019-02-10
      • 1970-01-01
      • 2014-10-05
      相关资源
      最近更新 更多