cengiz-pz / godot-ios-share-plugin

Godot iOS Share plugin allows sharing of text and images on iOS platform
MIT License
3 stars 0 forks source link

Tested on v4.2.2.stable.official [15073afe3] - ARCHIVE FAILED #1

Closed TheOathMan closed 1 week ago

TheOathMan commented 1 week ago

The Plugin was tested with Godot v4.2.2.stable.official.

System: MacBook Air (13-inch, 2017) Mac version 12.6.2 Xcode version: Version 14.2

The build failed while building archive in Godot. In Xcode, failed during build (when 'Export Project only' is Enabled from Godot export settings).

The following build commands failed:
    Ld /Users/main/Library/Developer/Xcode/DerivedData/testingg-gvofzswuhtpjdaeytstoiuocytua/Build/Intermediates.noindex/ArchiveIntermediates/testingg/InstallationBuildProductsLocation/Applications/testingg.app/testingg normal (in target 'testingg' from project 'testingg')
(1 failure)

This is while building on Godot. But Xcode gave extra details:

clang: error: no such file or directory: '/Users/main/Desktop/Godot_Builds/forXcode/testingg/ios/plugins/SharePlugin.release.a'

Impotent to note that, not only this plugin failed, pretty much every plugin I tested failed at this stage in my system with these configurations.

Can you provide your Godot version and Xcode version that this plugin worked on ?

cengiz-pz commented 1 week ago

Hi @TheOathMan, the plugin was tested with Xcode 15.2 (15C500b) and Godot 4.2.1. From your error message, it looks like the plugin wasn't installed correctly. What is the actual directory path for the SharePlugin.release.a archive file? It should be in the [your project root]/ios/plugins directory

TheOathMan commented 1 week ago

That's correct. The share plugin is installed at [your project root]/ios/plugins. I have tested 2 other plugins, but i still get the same error message so i doubt its related to your implementation. I have great suspicion that it's an xcode version related error or Godot version related error or both. I Even built my own share plugin, same error message. Plugins on Godot v4.0.1 worked though.

The only thing that worked in Godot v4.2.2.stable was not adding a plugin file to my Godot project, but rather building plugin inside an already exported xcode project. So no .a or .xcfromeork files. I was able to get a share functionality working this way. I had to add reference to Godot headers and added compile flags to my xcode to get it working.

I will continue investigating to see the root of this issue.

TheOathMan commented 1 week ago

I found the issue. Somehow this version of Xcode doesn't like dot in xcode project names, and Godot by default adds .ipa after your Godot project name in the Export panel. That made the path to the framework invalid. So it's a mixture of Godot issue and xcode issue The solution is to remove all dots in the Export panel and just leave the project name.