Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Question XCode build fail when add Apple.GameKit plugin for Unity: Undefined symbol

Discussion in 'iOS and tvOS' started by letuantam96, Dec 7, 2022.

  1. letuantam96

    letuantam96

    Joined:
    Feb 6, 2020
    Posts:
    9
    Hi guys,
    I have a Unity project, after setting up Apple.Gamekit plugin, it show up some error when build with XCode:
    Code (CSharp):
    1. ...
    2. _GKTurnBasedMatch_GKTurnBasedMatch_SetMatchEndedCallback_m910C3F81D2AC3130B65F3F62FC964A7AB1BB4BB4 in Apple.GameKit.o
    3.       _GKTurnBasedMatch__cctor_m700F9804CBB4DB33EDE51763CB6CE3D5DCA9005C in Apple.GameKit.o
    4.      (maybe you meant: _GKTurnBasedMatch_GKTurnBasedMatch_SetMatchEndedCallback_m910C3F81D2AC3130B65F3F62FC964A7AB1BB4BB4)
    5.   "_NSArray_Free", referenced from:
    6.       _NSArray_NSArray_Free_mC93688296693996DD20C704745DBDB169462AA95 in Apple.Core.o
    7.       _NSArray_OnDispose_m3D3F7A2BCD4038EB98125421A35CA23FCA9FF395 in Apple.Core.o
    8.      (maybe you meant: _NSArray_NSArray_Free_mC93688296693996DD20C704745DBDB169462AA95)
    9.   "_GKLeaderboard_SubmitScore", referenced from:
    10.       _GKLeaderboard_GKLeaderboard_SubmitScore_m2B37BEF38FD1A631ED4A06A894B7360A9ECDFF47 in Apple.GameKit.o
    11.       _GKLeaderboard_SubmitScore_m857EAFCB86A50F186998E8A78A22778F4AE961BD in Apple.GameKit.o
    12.      (maybe you meant: GKLeaderboard_GKLeaderboard_SubmitScore_m2B37BEF38FD1A631ED4A06A894B7360A9ECDFF47, GKLeaderboard_SubmitScore_m857EAFCB86A50F186998E8A78A22778F4AE961BD )
    13. ld: symbol(s) not found for architecture arm64
    14. clang: error: linker command failed with exit code 1 (use -v to see invocation)
    15.  
    16. Showing Recent Messages
    17. Undefined symbol: _NSArray_GetGKTurnBasedExchangeReplyAt
    18.  
    19. Showing Recent Messages
    20. Undefined symbol: _NSArray_GetGKLeaderboardEntryAt
    21.  
    22. Showing Recent Messages
    23. Undefined symbol: _NSArray_GetGKLeaderboardAt
    The plugin I added, which is provided by Apple: https://github.com/apple/unityplugins

    What I tried so far:

    • Re-install Apple.Core and Apple.GameKit
    • Re-install pod
    • Update XCode to version 14.1
    But nothing works.

    Please help! Thank you!!!
     
    parker_layer0 likes this.
  2. Dzxyan

    Dzxyan

    Joined:
    Sep 23, 2013
    Posts:
    167
    me have same issues, do you fixed the issues?
     
    parker_layer0 likes this.
  3. heliosmini

    heliosmini

    Joined:
    Jun 23, 2022
    Posts:
    1
    You need to build with the correct Unity version they recommend in the document