diff --git a/Package.swift b/Package.swift index 057ba655b3a..411402e1823 100644 --- a/Package.swift +++ b/Package.swift @@ -1,4 +1,4 @@ -// swift-tools-version:5.1 +// swift-tools-version:5.3 import PackageDescription let package = Package( @@ -18,6 +18,9 @@ let package = Package( "Sentry/", "SentryCrash/" ], + resources: [ + .copy("Resources/PrivacyInfo.xcprivacy") + ], publicHeadersPath: "Sentry/Public/", cxxSettings: [ .define("GCC_ENABLE_CPP_EXCEPTIONS", to: "YES"), diff --git a/Sentry.podspec b/Sentry.podspec index f660af3a93c..44b4489f220 100644 --- a/Sentry.podspec +++ b/Sentry.podspec @@ -34,6 +34,7 @@ Pod::Spec.new do |s| "Sources/SentryCrash/**/*.{h,hpp,m,mm,c,cpp}", "Sources/Swift/Sentry.swift" sp.public_header_files = "Sources/Sentry/Public/*.h" + sp.resource = "Sources/Resources/PrivacyInfo.xcprivacy" end s.subspec 'HybridSDK' do |sp| @@ -42,5 +43,7 @@ Pod::Spec.new do |s| sp.public_header_files = "Sources/Sentry/Public/*.h", "Sources/Sentry/include/HybridPublic/*.h" + + sp.resource = "Sources/Resources/PrivacyInfo.xcprivacy" end end diff --git a/Sentry.xcodeproj/project.pbxproj b/Sentry.xcodeproj/project.pbxproj index 675a1babce7..5bac35a3a0e 100644 --- a/Sentry.xcodeproj/project.pbxproj +++ b/Sentry.xcodeproj/project.pbxproj @@ -793,6 +793,7 @@ D8ACE3CD2762187D00F5A213 /* SentryNSDataSwizzling.h in Headers */ = {isa = PBXBuildFile; fileRef = D8ACE3CA2762187D00F5A213 /* SentryNSDataSwizzling.h */; }; D8ACE3CE2762187D00F5A213 /* SentryNSDataTracker.h in Headers */ = {isa = PBXBuildFile; fileRef = D8ACE3CB2762187D00F5A213 /* SentryNSDataTracker.h */; }; D8ACE3CF2762187D00F5A213 /* SentryFileIOTrackingIntegration.h in Headers */ = {isa = PBXBuildFile; fileRef = D8ACE3CC2762187D00F5A213 /* SentryFileIOTrackingIntegration.h */; }; + D8B0542E2A7D2C720056BAF6 /* PrivacyInfo.xcprivacy in Resources */ = {isa = PBXBuildFile; fileRef = D8B0542D2A7D2C720056BAF6 /* PrivacyInfo.xcprivacy */; }; D8B088B629C9E3FF00213258 /* SentryTracerConfiguration.h in Headers */ = {isa = PBXBuildFile; fileRef = D8B088B429C9E3FF00213258 /* SentryTracerConfiguration.h */; }; D8B088B729C9E3FF00213258 /* SentryTracerConfiguration.m in Sources */ = {isa = PBXBuildFile; fileRef = D8B088B529C9E3FF00213258 /* SentryTracerConfiguration.m */; }; D8B76B062808066D000A58C4 /* SentryScreenshotIntegrationTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = D8B76B042808060E000A58C4 /* SentryScreenshotIntegrationTests.swift */; }; @@ -1535,7 +1536,6 @@ 84281C652A58A16500EE88F2 /* SentryProfiler+Test.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "SentryProfiler+Test.h"; sourceTree = ""; }; 8431EE5A29ADB8EA00D8DC56 /* SentryTimeTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SentryTimeTests.m; sourceTree = ""; }; 8431EFD929B27B1100D8DC56 /* SentryProfilerTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = SentryProfilerTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; - 8431EFDA29B27B1200D8DC56 /* SentryTests copy-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; name = "SentryTests copy-Info.plist"; path = "/Users/andrewmcknight/Code/organization/getsentry/repos/public/sentry-cocoa/SentryTests copy-Info.plist"; sourceTree = ""; }; 8431F00A29B284F200D8DC56 /* libSentryTestUtils.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libSentryTestUtils.a; sourceTree = BUILT_PRODUCTS_DIR; }; 84354E0F29BF944900CDBB8B /* SentryProfileTimeseries.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = SentryProfileTimeseries.h; path = Sources/Sentry/include/SentryProfileTimeseries.h; sourceTree = SOURCE_ROOT; }; 84354E1029BF944900CDBB8B /* SentryProfileTimeseries.mm */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.objcpp; name = SentryProfileTimeseries.mm; path = Sources/Sentry/SentryProfileTimeseries.mm; sourceTree = SOURCE_ROOT; }; @@ -1548,7 +1548,6 @@ 844DA80628246D5000E6B62E /* .craft.yml */ = {isa = PBXFileReference; lastKnownFileType = text.yaml; path = .craft.yml; sourceTree = ""; }; 844DA80728246D5000E6B62E /* Gemfile */ = {isa = PBXFileReference; explicitFileType = text.script.ruby; path = Gemfile; sourceTree = ""; }; 844DA80828246D5000E6B62E /* .gitmodules */ = {isa = PBXFileReference; lastKnownFileType = text; path = .gitmodules; sourceTree = ""; }; - 844DA80928246D5000E6B62E /* dangerfile.js */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.javascript; path = dangerfile.js; sourceTree = ""; }; 844DA80A28246D5000E6B62E /* .swiftlint.yml */ = {isa = PBXFileReference; lastKnownFileType = text.yaml; path = .swiftlint.yml; sourceTree = ""; }; 844DA80B28246D5000E6B62E /* Brewfile */ = {isa = PBXFileReference; explicitFileType = text.script.ruby; path = Brewfile; sourceTree = ""; }; 844DA80C28246D5000E6B62E /* CHANGELOG.md */ = {isa = PBXFileReference; lastKnownFileType = net.daringfireball.markdown; path = CHANGELOG.md; sourceTree = ""; }; @@ -1743,6 +1742,7 @@ D8ACE3CA2762187D00F5A213 /* SentryNSDataSwizzling.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SentryNSDataSwizzling.h; path = include/SentryNSDataSwizzling.h; sourceTree = ""; }; D8ACE3CB2762187D00F5A213 /* SentryNSDataTracker.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SentryNSDataTracker.h; path = include/SentryNSDataTracker.h; sourceTree = ""; }; D8ACE3CC2762187D00F5A213 /* SentryFileIOTrackingIntegration.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SentryFileIOTrackingIntegration.h; path = include/SentryFileIOTrackingIntegration.h; sourceTree = ""; }; + D8B0542D2A7D2C720056BAF6 /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; lastKnownFileType = text.xml; path = PrivacyInfo.xcprivacy; sourceTree = ""; }; D8B088B429C9E3FF00213258 /* SentryTracerConfiguration.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = SentryTracerConfiguration.h; path = include/SentryTracerConfiguration.h; sourceTree = ""; }; D8B088B529C9E3FF00213258 /* SentryTracerConfiguration.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SentryTracerConfiguration.m; sourceTree = ""; }; D8B76B042808060E000A58C4 /* SentryScreenshotIntegrationTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SentryScreenshotIntegrationTests.swift; sourceTree = ""; }; @@ -2005,7 +2005,6 @@ 844DA80728246D5000E6B62E /* Gemfile */, 844DA80428246D5000E6B62E /* Makefile */, 844DA81F28246DE300E6B62E /* scripts */, - 844DA80928246D5000E6B62E /* dangerfile.js */, 844DA81B28246D9300E6B62E /* Brewfile.lock.json */, 844DA81C28246D9300E6B62E /* Gemfile.lock */, 844DA80C28246D5000E6B62E /* CHANGELOG.md */, @@ -2027,7 +2026,6 @@ 8431F00B29B284F200D8DC56 /* SentryTestUtils */, 7D826E3C2390840E00EED93D /* Utils */, D8105B37297A86B800299F03 /* Recovered References */, - 8431EFDA29B27B1200D8DC56 /* SentryTests copy-Info.plist */, ); indentWidth = 4; sourceTree = ""; @@ -2193,6 +2191,7 @@ D800942328F82E8D005D3943 /* Swift */, 63FE6FB920DA4C1000CDBAE8 /* SentryCrash */, 63AA75A31EB8AFDF00D153DE /* Configuration */, + D8B0542F2A7D35F10056BAF6 /* Resources */, ); path = Sources; sourceTree = ""; @@ -3398,6 +3397,14 @@ name = IO; sourceTree = ""; }; + D8B0542F2A7D35F10056BAF6 /* Resources */ = { + isa = PBXGroup; + children = ( + D8B0542D2A7D2C720056BAF6 /* PrivacyInfo.xcprivacy */, + ); + path = Resources; + sourceTree = ""; + }; D8F01DE32A125D7B008F4996 /* HybridSDKTest */ = { isa = PBXGroup; children = ( @@ -3911,6 +3918,7 @@ isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( + D8B0542E2A7D2C720056BAF6 /* PrivacyInfo.xcprivacy in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -4681,10 +4689,11 @@ "$(inherited)", ); GCC_WARN_SHADOW = YES; - INFOPLIST_FILE = Sources/Sentry/Info.plist; + INFOPLIST_FILE = Sources/Resources/Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_DYLIB_INSTALL_NAME = "$(DYLIB_INSTALL_NAME_BASE:standardizepath)/$(EXECUTABLE_PATH)"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + MODULEMAP_FILE = "$(SRCROOT)/Sources/Resources/Sentry.modulemap"; ONLY_ACTIVE_ARCH = YES; OTHER_CFLAGS = "-DCARTHAGE_$(CARTHAGE)"; PRODUCT_BUNDLE_IDENTIFIER = io.sentry.Sentry; @@ -4719,10 +4728,11 @@ GCC_C_LANGUAGE_STANDARD = "compiler-default"; GCC_OPTIMIZATION_LEVEL = s; GCC_WARN_SHADOW = YES; - INFOPLIST_FILE = Sources/Sentry/Info.plist; + INFOPLIST_FILE = Sources/Resources/Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_DYLIB_INSTALL_NAME = "$(DYLIB_INSTALL_NAME_BASE:standardizepath)/$(EXECUTABLE_PATH)"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + MODULEMAP_FILE = "$(SRCROOT)/Sources/Resources/Sentry.modulemap"; ONLY_ACTIVE_ARCH = NO; OTHER_CFLAGS = "-DCARTHAGE_$(CARTHAGE)"; PRODUCT_BUNDLE_IDENTIFIER = io.sentry.Sentry; @@ -4873,10 +4883,11 @@ "TESTCI=1", ); GCC_WARN_SHADOW = YES; - INFOPLIST_FILE = Sources/Sentry/Info.plist; + INFOPLIST_FILE = Sources/Resources/Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_DYLIB_INSTALL_NAME = "$(DYLIB_INSTALL_NAME_BASE:standardizepath)/$(EXECUTABLE_PATH)"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + MODULEMAP_FILE = "$(SRCROOT)/Sources/Resources/Sentry.modulemap"; ONLY_ACTIVE_ARCH = YES; OTHER_CFLAGS = "-DCARTHAGE_$(CARTHAGE)"; PRODUCT_BUNDLE_IDENTIFIER = io.sentry.Sentry; @@ -5219,10 +5230,11 @@ GCC_C_LANGUAGE_STANDARD = "compiler-default"; GCC_OPTIMIZATION_LEVEL = 0; GCC_WARN_SHADOW = YES; - INFOPLIST_FILE = Sources/Sentry/Info.plist; + INFOPLIST_FILE = Sources/Resources/Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_DYLIB_INSTALL_NAME = "$(DYLIB_INSTALL_NAME_BASE:standardizepath)/$(EXECUTABLE_PATH)"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + MODULEMAP_FILE = "$(SRCROOT)/Sources/Resources/Sentry.modulemap"; ONLY_ACTIVE_ARCH = YES; OTHER_CFLAGS = "-DCARTHAGE_$(CARTHAGE)"; PRODUCT_BUNDLE_IDENTIFIER = io.sentry.Sentry; diff --git a/Sources/Sentry/Info.plist b/Sources/Resources/Info.plist similarity index 100% rename from Sources/Sentry/Info.plist rename to Sources/Resources/Info.plist diff --git a/Sources/Resources/PrivacyInfo.xcprivacy b/Sources/Resources/PrivacyInfo.xcprivacy new file mode 100644 index 00000000000..2433f73fdba --- /dev/null +++ b/Sources/Resources/PrivacyInfo.xcprivacy @@ -0,0 +1,25 @@ + + + + + NSPrivacyAccessedAPITypes + + + NSPrivacyAccessedAPIType + NSPrivacyAccessedAPICategoryUserDefaults + NSPrivacyAccessedAPITypeReasons + + CA92.1 + + + + NSPrivacyAccessedAPIType + NSPrivacyAccessedAPICategorySystemBootTime + NSPrivacyAccessedAPITypeReasons + + 35F9.1 + + + + + diff --git a/Sources/Sentry/Sentry.modulemap b/Sources/Resources/Sentry.modulemap similarity index 100% rename from Sources/Sentry/Sentry.modulemap rename to Sources/Resources/Sentry.modulemap