Xcode 7 simulator error "duplicate symbols for architecture x86_64"

12,099

Solution 1

This error generally occurs when you have linked any library or file twice. In the error desciption, the name of the duplicated file will be listed, you can search and and make sure you don't have duplicates. If you find duplicates, remove reference to one of them to play safe

Solution 2

I have faced similar kind of issue.

In my application I have run my code and created ipa before two day. And today when I am trying to run same code without any changes I am getting:

ld: 102 duplicate symbols for architecture x86_64 clang: error: linker command failed with exit code 1 (use -v to see invocation)

The solution for this duplication Linker error can be solved by Remove all of your classes from compile sources, then click the + button and search for the term '.m'. Highlight every class, then click add. Build and run again.

Share:
12,099
Admin
Author by

Admin

Updated on June 07, 2022

Comments

  • Admin
    Admin almost 2 years

    My development environment with Xcode 7.2.1, CocoaPods 1.0.0 and GoogleMaps 1.13.2

    I can build code successful to generate a XXX.ipa file and install in my iPhone 6 Plus to work correctly.

    But when I run Xcode simulator by item "iPhone 6" or "iPhone 6 Plus" always get the information as below

    "xxxx duplicate symbols for architecture x86_64" "linker command failed with exit code 1 (use -v to see invocation)"

    I use the following solutions still can't fix it

    1. Build Options -> Enable Bitcode -> set "No"

    2. Remove -ObjC from Other Linker Flags

    3. project Targer -> Build phases -> compile sources, ckeck no duplicate files

    4. Make sure I haven't #imported a .m file

    I am wondering if there are any other method to solve this, help would be appreciated thanks.