Skip to content

Commit

Permalink
fix: Xcode Sentry.framework import (#442)
Browse files Browse the repository at this point in the history
  • Loading branch information
bitsandfoxes authored Dec 1, 2021
1 parent dd1351d commit 940a85e
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Changelog

## Unreleased

### Fixes

- Sentry no longer requires Xcode projects to be exported on macOS ([#442](https://github.com/getsentry/sentry-unity/pull/442))

## 0.7.0

### Features
Expand Down
2 changes: 1 addition & 1 deletion src/Sentry.Unity.Editor.iOS/BuildPostProcess.cs
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ private static void CopyFrameworkToBuildDirectory(string pathToProject, IDiagnos
var packageName = SentryPackageInfo.GetName();
var frameworkDirectory = PlayerSettings.iOS.sdkVersion == iOSSdkVersion.DeviceSDK ? "Device" : "Simulator";

var frameworkPath = Path.Combine("Packages", packageName, "Plugins", "iOS", frameworkDirectory, "Sentry.framework");
var frameworkPath = Path.GetFullPath(Path.Combine("Packages", packageName, "Plugins", "iOS", frameworkDirectory, "Sentry.framework"));
if (Directory.Exists(frameworkPath))
{
logger?.LogDebug("Copying Sentry.framework from '{0}' to '{1}'", frameworkPath, targetPath);
Expand Down
4 changes: 2 additions & 2 deletions src/Sentry.Unity.Editor.iOS/SentryXcodeProject.cs
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ internal void ReadFromProjectFile()

public void AddSentryFramework()
{
var frameworkPath = Path.Combine(_projectRoot, "Frameworks", FrameworkName);
var frameworkGuid = _project.AddFile(frameworkPath, frameworkPath);
var relativeFrameworkPath = Path.Combine("Frameworks", FrameworkName);
var frameworkGuid = _project.AddFile(relativeFrameworkPath, relativeFrameworkPath);

var mainTargetGuid = _project.GetUnityMainTargetGuid();
var unityFrameworkTargetGuid = _project.GetUnityFrameworkTargetGuid();
Expand Down

0 comments on commit 940a85e

Please sign in to comment.