|
7 | 7 | <IsBindingProject>true</IsBindingProject>
|
8 | 8 | <NoBindingEmbedding>true</NoBindingEmbedding>
|
9 | 9 | <!-- Don't remove native symbols, because it makes debugging native crashes harder -->
|
| 10 | + <SentryCocoaSdkVersion>7.17.0</SentryCocoaSdkVersion> |
10 | 11 | <MtouchNoSymbolStrip>true</MtouchNoSymbolStrip>
|
11 |
| - <iOSLibsDirectory>$(MSBuildProjectDirectory)/../../libs/iOS/</iOSLibsDirectory> |
| 12 | + <iOSLibsDirectory>$(BaseIntermediateOutputPath)/libs/iOS/</iOSLibsDirectory> |
| 13 | + <iOSFramework>$(iOSLibsDirectory)Sentry.xcframework/Carthage/Build/Sentry.xcframework</iOSFramework> |
12 | 14 | </PropertyGroup>
|
13 | 15 |
|
14 | 16 | <ItemGroup>
|
|
18 | 20 | <ItemGroup>
|
19 | 21 | <ObjcBindingApiDefinition Include="iOS/ApiDefinition.cs" />
|
20 | 22 | <ObjcBindingCoreSource Include="iOS/Structs.cs" />
|
21 |
| - <NativeReference Include="$(iOSLibsDirectory)/Sentry.xcframework"> |
| 23 | + <NativeReference Include="$(iOSFramework)"> |
22 | 24 | <Kind>Framework</Kind>
|
23 | 25 | <SmartLink>False</SmartLink>
|
24 | 26 | <!-- <Frameworks>CoreLocation ModelIO</Frameworks> -->
|
|
30 | 32 | <Using Include="System.Text.Json" />
|
31 | 33 | </ItemGroup>
|
32 | 34 |
|
33 |
| - <!-- Update Android SDK: Update SentryAndroidSdkVersion and run: |
34 |
| - dotnet msbuild src/Sentry /t:DownloadSentryAndroidSdk /p:TargetFramework=net6.0-android --> |
35 |
| - <Target Name="DownloadSentryAndroidSdk"> |
36 |
| - <RemoveDir Directories="$(AndroidLibsDirectory)" /> |
37 |
| - <DownloadFile SourceUrl="https://repo1.maven.org/maven2/io/sentry/sentry-android-core/$(SentryAndroidSdkVersion)/sentry-android-core-$(SentryAndroidSdkVersion).aar" |
38 |
| - DestinationFolder="$(AndroidLibsDirectory)" |
39 |
| - SkipUnchangedFiles="true"> |
40 |
| - <Output TaskParameter="DownloadedFile" ItemName="Content" /> |
41 |
| - </DownloadFile> |
42 |
| - <DownloadFile SourceUrl="https://repo1.maven.org/maven2/io/sentry/sentry-android-ndk/$(SentryAndroidSdkVersion)/sentry-android-ndk-$(SentryAndroidSdkVersion).aar" |
43 |
| - DestinationFolder="$(AndroidLibsDirectory)" |
44 |
| - SkipUnchangedFiles="true"> |
45 |
| - <Output TaskParameter="DownloadedFile" ItemName="Content" /> |
46 |
| - </DownloadFile> |
47 |
| - <DownloadFile SourceUrl="https://repo1.maven.org/maven2/io/sentry/sentry/$(SentryAndroidSdkVersion)/sentry-$(SentryAndroidSdkVersion).jar" |
48 |
| - DestinationFolder="$(AndroidLibsDirectory)" |
49 |
| - SkipUnchangedFiles="true"> |
50 |
| - <Output TaskParameter="DownloadedFile" ItemName="Content" /> |
| 35 | + <Target Name="DownloadSentryCocoaSdk" BeforeTargets="CollectPackageReferences"> |
| 36 | + <DownloadFile SourceUrl="https://github.com/getsentry/sentry-cocoa/releases/download/$(SentryCocoaSdkVersion)/Sentry.xcframework.zip" |
| 37 | + DestinationFolder="$(iOSLibsDirectory)" |
| 38 | + Condition="!Exists('$(iOSLibsDirectory)Sentry.xcframework.zip')"> |
| 39 | + <Output TaskParameter="DownloadedFile" ItemName="None" /> |
51 | 40 | </DownloadFile>
|
| 41 | + <Unzip |
| 42 | + SourceFiles="$(iOSLibsDirectory)Sentry.xcframework.zip" |
| 43 | + DestinationFolder="$(iOSLibsDirectory)Sentry.xcframework" |
| 44 | + OverwriteReadOnlyFiles="true" |
| 45 | + /> |
52 | 46 | </Target>
|
53 | 47 |
|
54 | 48 | </Project>
|
0 commit comments