Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix iOS builds after the unity upgrade #733

Merged
merged 6 commits into from
Jun 26, 2024
Merged

Fix iOS builds after the unity upgrade #733

merged 6 commits into from
Jun 26, 2024

Conversation

mikeage
Copy link
Member

@mikeage mikeage commented Jun 26, 2024

Set ld_classic via fastfile

Online sources suggest that the following change should also work, but I
saw that it wasn't being passed to the link call. So we'll do it this
way.

diff --git a/Assets/Editor/BuildTiltBrush.cs b/Assets/Editor/BuildTiltBrush.cs
index 8e5652fc..314d0eba 100644
--- a/Assets/Editor/BuildTiltBrush.cs
+++ b/Assets/Editor/BuildTiltBrush.cs
@@ -1824,6 +1824,9 @@ static class BuildTiltBrush
                     // TODO:Mikesky - I've disabled this disable, does bitcode work now?
                     //project.SetBuildProperty(pbxTarget, "ENABLE_BITCODE", "false");

+                    // Starting with the upgrade to Unity 2023, this seems to be required
+                    project.AddBuildProperty(pbxTarget, "OTHER_LDFLAGS", "-ld_classic");
+
                     File.WriteAllText(pbxPath, project.WriteToString());

                     string plistPath = path + "/Info.plist";

Additionally, this PR updates the fastlane action, and builds an ipa on all jobs. But we'll only push to testflight (or the app store) on a merge to main, like before. edit: no, this doesn't work because of the package name mismatch. maybe I'll fix this another day, but not here

mikeage added 5 commits June 26, 2024 08:09
Online sources suggest that the following change should also work, but I
saw that it wasn't being passed to the link call. So we'll do it this
way.

```
diff --git a/Assets/Editor/BuildTiltBrush.cs b/Assets/Editor/BuildTiltBrush.cs
index 8e5652fc..314d0eba 100644
--- a/Assets/Editor/BuildTiltBrush.cs
+++ b/Assets/Editor/BuildTiltBrush.cs
@@ -1824,6 +1824,9 @@ static class BuildTiltBrush
                     // TODO:Mikesky - I've disabled this disable, does bitcode work now?
                     //project.SetBuildProperty(pbxTarget, "ENABLE_BITCODE", "false");

+                    // Starting with the upgrade to Unity 2023, this seems to be required
+                    project.AddBuildProperty(pbxTarget, "OTHER_LDFLAGS", "-ld_classic");
+
                     File.WriteAllText(pbxPath, project.WriteToString());

                     string plistPath = path + "/Info.plist";
```
@mikeage mikeage requested a review from mikeskydev June 26, 2024 05:25
@mikeage mikeage added the infrastructure Build or tooling infrastructure label Jun 26, 2024
@mikeage mikeage merged commit 0cd60ff into main Jun 26, 2024
42 checks passed
@mikeage mikeage deleted the infra/fix_ios branch June 26, 2024 06:40
@mikeage mikeage mentioned this pull request Jun 26, 2024
9 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
infrastructure Build or tooling infrastructure
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant