Search Unity

Bug iOs Build Failure - arm64 function not 4-byte aligned

Discussion in 'Unity MARS' started by patpre, Apr 16, 2021.

  1. patpre

    patpre

    Joined:
    Jan 12, 2021
    Posts:
    28
    Hi,

    I am using the following versions:

    Unity - 2019.4.18f1
    AR Foundation - 2.1.18
    ARKit Face Tracking 1.0.13
    ARKit XR Plugin 2.1.18
    Mars 1.3.

    All that I am using is mainly coming from these packages. Apart I have added an SDK for Shopify (new version and compatible with 2019.x).

    Everything works fine in separate Projects - but when combining these functions all together in one project, the following problem occurs. Within Unity everything works fine, but when trying to deploy to iOS Device the following error occurs:

    ld: warning: arm64 function not 4-byte aligned: _unwind_tester from /Users/XXXX/Documents/#XXXX/Unity_Projects/XXXX/Builds/Build5/Libraries/libiPhone-lib.a(unwind_test_arm64.o)

    duplicate symbol 'malloc_allocator::deallocate(void*)' in:

    /Users/XXXX/Documents/#XXXX/Unity_Projects/XXXX/Builds/Build5/Libraries/com.unity.xr.arkit-face-tracking/Runtime/iOS/libUnityARKitFaceTracking.a(malloc_allocator.o)

    /Users/XXXX/Documents/#XXXX/Unity_Projects/XXXX/Builds/Build5/Libraries/com.unity.xr.arkit/Runtime/iOS/UnityARKit.a(malloc_allocator.o)

    It seems that there is an issue with the face tracking package. Just for finding out, I have removed the face tracking package and I was able to install it to the iOS device without problems... But I need the face Tracking for my app :-( therefore I am looking for help on this!

    Thanks!!
     
  2. jmunozarUTech

    jmunozarUTech

    Unity Technologies

    Joined:
    Jun 1, 2020
    Posts:
    297
    hello @patpre,

    This seems to be an ARkit problem with Shopify's SDK; Does this issue also appears on a project without MARS installed?. could yo check if with different versions of ARFoundation/ARKit and the Shopify SDK (Not MARS, just those) the problem persists?

    Also, could you try making a build again with your setup but making sure you select the "Symlink Unity Libraries" checkbox and tell us if this solves your issue?

    Looking forward to see your results
     

    Attached Files:

  3. patpre

    patpre

    Joined:
    Jan 12, 2021
    Posts:
    28
    Hello,

    I already checked with different versions- unfortunately no luck with that. But even if it would help, it wouldn't help me a lot as you can see from thread (Mars Facemask weird behavior on iOS) - I don't have a lot of alternatives when it comes to versions... Also tried the approach with the "Symlink Unity Libraries" - also no luck.

    Running it with ARFoundation, ARKit, ARKit Facetracking without Mars - same result. The same error keeps popping up :-(

    Any other suggestions to get this fixed? Looking forward hearing from you! Thanks!!!
     
  4. jmunozarUTech

    jmunozarUTech

    Unity Technologies

    Joined:
    Jun 1, 2020
    Posts:
    297
    hello @patpre,

    We are aware of the other post with regards to facemasks, but seems this problem has to do with Shopify and ARFoundation/ARKit and not with MARS.

    Also, from the stack trace you shared with us, seems to be a warning and no errors; what type of lacking functionality are you seeing?, is your app crashing / not behaving like it should?

    also; @patpre, could you create a bug report and submit your project so we can have a look into it?
     
    Last edited: Apr 16, 2021
  5. patpre

    patpre

    Joined:
    Jan 12, 2021
    Posts:
    28
    hello,

    Thanks for the quick feedback. Unfortunately it is not a warning, as I can build the project in unity, but I cannot deploy it to the iPhone due to this error --> the app is not being installed to the iOS device.

    I will take the opportunity to create a bug report - maybe this will help to fix this issue - this would be so great!

    Thanks!!
     
    jmunozarUTech likes this.
  6. jmunozarUTech

    jmunozarUTech

    Unity Technologies

    Joined:
    Jun 1, 2020
    Posts:
    297
    Awesome!,

    Thanks @patpre, When you submit the bug report, please let us know the case Id so we can check that out and inspect your project. :)
     
  7. patpre

    patpre

    Joined:
    Jan 12, 2021
    Posts:
    28
    Thanks! The ID is 1329731. Would be great to hear back from you soon! Thanks!