0

这是我尝试构建应用程序时遇到的错误。

ld:架构 arm64 的 10 个重复符号

在此处输入图像描述

4

4 回答 4

0

Your project twice referring to file SetLockViewController.m. My suggestion is take a copy of class out side of your project.

[1] Then right click on SetLockViewController.m file and delete > move to trash.

[2] Go to project files directory in finder. Then delete the file SetLockViewController.m (if you find any).

[3] Clean the build and run.

Follow same method if any other duplicate files/linker errors present.

于 2016-01-15T04:14:03.227 回答
0

请检查项目的每个类中的所有变量名称,并确保它们都具有唯一的名称,包括类外

于 2016-01-15T11:14:17.267 回答
0

从错误中,我猜想:

  • 你有两个文件,VaultSelectionViewController.m并且SetLockViewController.m(第一个最初是第二个的副本,可能)

  • 它们都包含@implementation SetLockViewController, 和相同的属性和/或方法和/或实例变量。

解决方法:修复类名中@implementation的文件名。

如果这不是问题,请提供两个文件的相关部分。

于 2016-01-15T03:13:25.933 回答
0

在此处输入图像描述

  1. 确保您的编译源没有 dup 文件。(错误的合并可能会导致此问题。)删除它们并再次添加它们可以修复此构建错误。

  2. 确保您没有两次实现一个功能。(复制代码而忘记重命名@implement XXX?或者复制并粘贴一个函数两次?)只需搜索项目中定义的函数并删除重复的函数。

于 2016-01-15T10:16:06.160 回答