Skip to content

chore(deps): update Cocoa SDK to v8.53.2 #2237

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

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,8 @@ jobs:
run: |
# Note: remove local.properties file that contains Android SDK & NDK paths in the Unity installation.
rm -rf samples/IntegrationTest/Build/*_BackUpThisFolder_ButDontShipItWithYourGame
tar -cvzf test-app-runtime.tar.gz samples/IntegrationTest/Build
# Use tar with extended attributes to preserve XCFramework signatures
tar -cvzf test-app-runtime.tar.gz samples/IntegrationTest/Build --xattrs --xattrs-include="*"

# Upload runtime initialization build
- name: Upload test app
Expand Down Expand Up @@ -300,7 +301,10 @@ jobs:
name: testapp-${{ matrix.platform }}-${{ matrix.unity-version }}-runtime

- name: Extract test app
run: tar -xvzf test-app-runtime.tar.gz
shell: bash
run: |
# Use tar with extended attributes to preserve XCFramework signatures
tar -xvzf test-app-runtime.tar.gz --xattrs --xattrs-include="*"

- name: Run (WebGL)
if: ${{ matrix.platform == 'WebGL' }}
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/smoke-test-build-ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,8 @@ jobs:
run: |
# Note: remove local.properties file that contains Android SDK & NDK paths in the Unity installation.
rm -rf samples/IntegrationTest/Build/*_BackUpThisFolder_ButDontShipItWithYourGame
tar -cvzf test-app-runtime.tar.gz samples/IntegrationTest/Build
# Use tar with extended attributes to preserve XCFramework signatures
tar -cvzf test-app-runtime.tar.gz samples/IntegrationTest/Build --xattrs --xattrs-include="*"

# Upload runtime initialization build
- name: Upload test app
Expand All @@ -100,7 +101,8 @@ jobs:
shell: bash
run: |
rm -rf samples/IntegrationTest/Build/*_BackUpThisFolder_ButDontShipItWithYourGame
tar -cvzf test-app-buildtime.tar.gz samples/IntegrationTest/Build
# Use tar with extended attributes to preserve XCFramework signatures
tar -cvzf test-app-buildtime.tar.gz samples/IntegrationTest/Build --xattrs --xattrs-include="*"

# Upload build-time initialization build
- name: Upload test app (build-time initialization)
Expand Down
5 changes: 4 additions & 1 deletion .github/workflows/smoke-test-compile-ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,10 @@ jobs:
name: testapp-ios-${{ env.UNITY_VERSION }}-${{ env.INIT_TYPE }}

- name: Extract app project
run: tar -xvzf test-app-${env:INIT_TYPE}.tar.gz
shell: bash
run: |
# Use tar with extended attributes to preserve XCFramework signatures
tar -xvzf test-app-${INIT_TYPE}.tar.gz --xattrs --xattrs-include="*"

- name: iOS smoke test
run: ./scripts/smoke-test-ios.ps1 Build -IsIntegrationTest -UnityVersion "${env:UNITY_VERSION}" -iOSMinVersion "16.1"
Expand Down
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
- Bump CLI from v2.47.1 to v2.50.2 ([#2245](https://github.com/getsentry/sentry-unity/pull/2245), [#2250](https://github.com/getsentry/sentry-unity/pull/2250))
- [changelog](https://github.com/getsentry/sentry-cli/blob/master/CHANGELOG.md#2502)
- [diff](https://github.com/getsentry/sentry-cli/compare/2.47.1...2.50.2)
- Bump Cocoa SDK from v8.51.0 to v8.53.2 ([#2237](https://github.com/getsentry/sentry-unity/pull/2237))
- [changelog](https://github.com/getsentry/sentry-cocoa/blob/main/CHANGELOG.md#8532)
- [diff](https://github.com/getsentry/sentry-cocoa/compare/8.51.0...8.53.2)

## 4.0.0-beta.0

Expand Down
8 changes: 3 additions & 5 deletions Directory.Build.targets
Original file line number Diff line number Diff line change
Expand Up @@ -215,11 +215,9 @@ Expected to exist:
Command="unzip -o $(SentryCocoaCache)Sentry-Dynamic-$(CocoaVersion).xcframework.zip -d $(SentryCocoaCache)" />

<!-- Set up the iOS support -->
<ItemGroup>
<!-- Itemgroup for the output Sentry.framework so we have access to '%(RecursiveDir)' when copying -->
<xcframeworkdPath Include="$(SentryCocoaCache)/Sentry-Dynamic.xcframework/**/*" />
</ItemGroup>
<Copy SourceFiles="@(xcframeworkdPath)" DestinationFiles="@(xcframeworkdPath->'$(SentryiOSArtifactsDestination)%(RecursiveDir)%(Filename)%(Extension)')" />
<MakeDir Directories="$(SentryiOSArtifactsDestination)" />
<!-- Use cp -R to preserve code signatures instead of MSBuild Copy task -->
<Exec Command="cp -R &quot;$(SentryCocoaCache)Sentry-Dynamic.xcframework/.&quot; &quot;$(SentryiOSArtifactsDestination)&quot;" />
<Error Condition="(!Exists('$(SentryiOSArtifactsDestination)'))" Text="Failed to set up the iOS SDK." />

<!-- Set up the macOS support -->
Expand Down
2 changes: 1 addition & 1 deletion modules/sentry-cocoa.properties
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
version = 8.51.0
version = 8.53.2
repo = https://github.com/getsentry/sentry-cocoa
16 changes: 13 additions & 3 deletions scripts/pack.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,13 @@ $exclude = @(
"assembly-alias.*"
)

Copy-Item "package-dev/*" "package-release/" -Exclude $exclude -Recurse
if ($IsLinux -or $IsMacOS) {
# Use cp -R to preserve XCFramework signatures and symlinks
bash -c 'for item in package-dev/*; do cp -R "$item" package-release/; done'
} else {
# On Windows (local dev only), signatures will be broken anyway - use simple copy
Copy-Item "package-dev/*" "package-release/" -Exclude $exclude -Recurse
}

# Override with package (e.g. custom .meta files)
Copy-Item "package/*" -Destination "package-release/" -Recurse -Force
Expand All @@ -25,5 +31,9 @@ Copy-Item "LICENSE.md" -Destination "package-release/LICENSE.md"
Copy-Item "samples/unity-of-bugs/Assets/Scenes*" -Destination "package-release/Samples~/unity-of-bugs/" -Recurse
Copy-Item "samples/unity-of-bugs/Assets/Scripts*" -Destination "package-release/Samples~/unity-of-bugs/" -Recurse

# Create zip
Compress-Archive "package-release/*" -DestinationPath "package-release.zip" -Force
# Create zip - use tar on Unix to preserve XCFramework signatures
if ($IsLinux -or $IsMacOS) {
bash -c 'cd package-release && tar -czf ../package-release.zip * --xattrs --xattrs-include="*"'
} else {
Compress-Archive "package-release/*" -DestinationPath "package-release.zip" -Force
}
23 changes: 22 additions & 1 deletion src/Sentry.Unity.Editor.iOS/BuildPostProcess.cs
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,28 @@ internal static void CopyFramework(string sourcePath, string targetPath, IDiagno
logger?.LogDebug("Copying from: '{0}' to '{1}'", sourcePath, targetPath);

Directory.CreateDirectory(Path.Combine(Path.GetDirectoryName(targetPath)));
FileUtil.CopyFileOrDirectory(sourcePath, targetPath);

// Use cp -R instead of FileUtil.CopyFileOrDirectory to preserve code signatures
var process = new System.Diagnostics.Process
{
StartInfo = new System.Diagnostics.ProcessStartInfo
{
FileName = "cp",
Arguments = $"-R \"{sourcePath}\" \"{targetPath}\"",
UseShellExecute = false,
RedirectStandardOutput = true,
RedirectStandardError = true
}
};

process.Start();
process.WaitForExit();

if (process.ExitCode != 0)
{
var error = process.StandardError.ReadToEnd();
logger?.LogError("Failed to copy framework with cp command: {0}", error);
}
}

if (!Directory.Exists(targetPath))
Expand Down
30 changes: 0 additions & 30 deletions src/Sentry.Unity.Editor/SentryFileUtil.cs

This file was deleted.

8 changes: 7 additions & 1 deletion test/Scripts.Integration.Test/extract-package.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,13 @@ if (Test-Path -Path "$PackageReleaseOutput")
Remove-Item -Path "$PackageReleaseOutput" -Recurse
}

Expand-Archive -LiteralPath "$(ProjectRoot)/$packageFile" -DestinationPath "$PackageReleaseOutput"
# Use tar to extract and preserve XCFramework signatures and symlinks
if ($IsLinux -or $IsMacOS) {
New-Item -Path "$PackageReleaseOutput" -ItemType Directory -Force
bash -c "cd `"$PackageReleaseOutput`" && tar -xzf `"$(ProjectRoot)/$packageFile`" --xattrs --xattrs-include=`"*`""
} else {
Expand-Archive -LiteralPath "$(ProjectRoot)/$packageFile" -DestinationPath "$PackageReleaseOutput"
}
Write-Host "OK"

If (-not(Test-Path -Path "$PackageReleaseOutput"))
Expand Down
Loading
Loading