diff --git a/.gitignore b/.gitignore index bbed34499..3bd4cf0a6 100644 --- a/.gitignore +++ b/.gitignore @@ -26,10 +26,11 @@ Pods *.orig # Adjust -Frameworks +frameworks +sdk_distribution # Code style uncrustify.cfg #SPM -.swiftpm/ \ No newline at end of file +.swiftpm/ diff --git a/Adjust.podspec b/Adjust.podspec index 22c56ae76..e3458b2ea 100644 --- a/Adjust.podspec +++ b/Adjust.podspec @@ -1,11 +1,11 @@ Pod::Spec.new do |s| s.name = "Adjust" - s.version = "4.30.0" + s.version = "4.31.0" s.summary = "This is the iOS SDK of adjust. You can read more about it at http://adjust.com." s.homepage = "https://github.com/adjust/ios_sdk" s.license = { :type => 'MIT', :file => 'MIT-LICENSE' } s.author = { "Adjust GmbH" => "sdk@adjust.com" } - s.source = { :git => "https://github.com/adjust/ios_sdk.git", :tag => "v4.30.0" } + s.source = { :git => "https://github.com/adjust/ios_sdk.git", :tag => "v4.31.0" } s.ios.deployment_target = '9.0' s.tvos.deployment_target = '9.0' s.framework = 'SystemConfiguration' diff --git a/Adjust.xcodeproj/project.pbxproj b/Adjust.xcodeproj/project.pbxproj index ecd70bef3..422975d26 100644 --- a/Adjust.xcodeproj/project.pbxproj +++ b/Adjust.xcodeproj/project.pbxproj @@ -22,6 +22,213 @@ /* End PBXAggregateTarget section */ /* Begin PBXBuildFile section */ + 0AB1C97627DD450D00509231 /* AdjustSdk.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 0AB1C97327DD450D00509231 /* AdjustSdk.h */; }; + 0AB1C99727DD4A9500509231 /* NSString+ADJAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 96CD2BDD1A13BFC600A40AFB /* NSString+ADJAdditions.m */; }; + 0AB1C99827DD4B3100509231 /* NSData+ADJAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 96C93DF41AC47F2E00B53F56 /* NSData+ADJAdditions.m */; }; + 0AB1C99927DD4B3100509231 /* NSNumber+ADJAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DF381A8260E990B0033F5A1 /* NSNumber+ADJAdditions.m */; }; + 0AB1C99A27DD4B3100509231 /* Adjust.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E34D18BBB48A008E7B30 /* Adjust.m */; }; + 0AB1C99B27DD4B3100509231 /* ADJActivityHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36318BBB48A008E7B30 /* ADJActivityHandler.m */; }; + 0AB1C99C27DD4B3100509231 /* ADJActivityKind.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36518BBB48A008E7B30 /* ADJActivityKind.m */; }; + 0AB1C99D27DD4B3100509231 /* ADJActivityPackage.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36718BBB48A008E7B30 /* ADJActivityPackage.m */; }; + 0AB1C99E27DD4B3100509231 /* ADJActivityState.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36918BBB48A008E7B30 /* ADJActivityState.m */; }; + 0AB1C99F27DD4B3100509231 /* ADJAdjustFactory.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37218BBB48A008E7B30 /* ADJAdjustFactory.m */; }; + 0AB1C9A027DD4B3100509231 /* ADJLogger.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37418BBB48A008E7B30 /* ADJLogger.m */; }; + 0AB1C9A127DD4B3100509231 /* ADJPackageBuilder.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37618BBB48A008E7B30 /* ADJPackageBuilder.m */; }; + 0AB1C9A227DD4B3100509231 /* ADJPackageParams.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DF92D822630ED02000FC3FC /* ADJPackageParams.m */; }; + 0AB1C9A327DD4B3100509231 /* ADJPackageHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37818BBB48A008E7B30 /* ADJPackageHandler.m */; }; + 0AB1C9A427DD4B3200509231 /* ADJRequestHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37A18BBB48A008E7B30 /* ADJRequestHandler.m */; }; + 0AB1C9A527DD4B3200509231 /* ADJUtil.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E38018BBB48A008E7B30 /* ADJUtil.m */; }; + 0AB1C9A627DD4B3200509231 /* ADJEvent.m in Sources */ = {isa = PBXBuildFile; fileRef = 9609BC6919EEA55800E02303 /* ADJEvent.m */; }; + 0AB1C9A727DD4B3200509231 /* ADJAttributionHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 969952CE1A012F5300928462 /* ADJAttributionHandler.m */; }; + 0AB1C9A827DD4B3200509231 /* ADJAttribution.m in Sources */ = {isa = PBXBuildFile; fileRef = 969952D11A01309200928462 /* ADJAttribution.m */; }; + 0AB1C9A927DD4B3200509231 /* ADJConfig.m in Sources */ = {isa = PBXBuildFile; fileRef = 960A8BB81A029A8000F2BB95 /* ADJConfig.m */; }; + 0AB1C9AA27DD4B3200509231 /* ADJTimerOnce.m in Sources */ = {isa = PBXBuildFile; fileRef = 96854A581B1F2779002B2874 /* ADJTimerOnce.m */; }; + 0AB1C9AB27DD4B3200509231 /* ADJTimerCycle.m in Sources */ = {isa = PBXBuildFile; fileRef = 96854A5E1B1F278C002B2874 /* ADJTimerCycle.m */; }; + 0AB1C9AC27DD4B3200509231 /* ADJResponseData.m in Sources */ = {isa = PBXBuildFile; fileRef = 96FCC5371C186426007BBFE1 /* ADJResponseData.m */; }; + 0AB1C9AD27DD4B3200509231 /* ADJSessionSuccess.m in Sources */ = {isa = PBXBuildFile; fileRef = 968173821C3C2D07002AE1DE /* ADJSessionSuccess.m */; }; + 0AB1C9AE27DD4B3200509231 /* ADJSessionFailure.m in Sources */ = {isa = PBXBuildFile; fileRef = 968173861C3C2D36002AE1DE /* ADJSessionFailure.m */; }; + 0AB1C9AF27DD4B3200509231 /* ADJEventSuccess.m in Sources */ = {isa = PBXBuildFile; fileRef = 9601CAE31C74B70600670879 /* ADJEventSuccess.m */; }; + 0AB1C9B027DD4B3200509231 /* ADJEventFailure.m in Sources */ = {isa = PBXBuildFile; fileRef = 9601CAE71C74BAAE00670879 /* ADJEventFailure.m */; }; + 0AB1C9B127DD4B3200509231 /* ADJBackoffStrategy.m in Sources */ = {isa = PBXBuildFile; fileRef = 965B7F2F1CC78F6600098639 /* ADJBackoffStrategy.m */; }; + 0AB1C9B227DD4B3200509231 /* ADJSdkClickHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96164D711CC8FA73009431AB /* ADJSdkClickHandler.m */; }; + 0AB1C9B327DD4B3200509231 /* ADJSessionParameters.m in Sources */ = {isa = PBXBuildFile; fileRef = 96B6710F1D788EEC0090A023 /* ADJSessionParameters.m */; }; + 0AB1C9B427DD4B3200509231 /* ADJUserDefaults.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DD0E9AD1F44690B00B2A759 /* ADJUserDefaults.m */; }; + 0AB1C9B527DD4B3200509231 /* ADJSubscription.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D2F23E12447CE5C00B7CA90 /* ADJSubscription.m */; }; + 0AB1C9B627DD4B3200509231 /* ADJUrlStrategy.m in Sources */ = {isa = PBXBuildFile; fileRef = 6FBEE8F224E2C26F00FEF3F1 /* ADJUrlStrategy.m */; }; + 0AB1C9B727DD4B3200509231 /* ADJThirdPartySharing.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D651BE125B25A64006D69D6 /* ADJThirdPartySharing.m */; }; + 0AB1C9B827DD4B3200509231 /* ADJAdRevenue.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D3A2AAA2625BEB800BD6E44 /* ADJAdRevenue.m */; }; + 0AB1C9B927DD4B3200509231 /* ADJLinkResolution.m in Sources */ = {isa = PBXBuildFile; fileRef = 6FAB784B2636DC0E00773869 /* ADJLinkResolution.m */; }; + 0AB1C9BA27DD4D7C00509231 /* Adjust.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 96E5E34C18BBB48A008E7B30 /* Adjust.h */; }; + 0AB1C9BB27DD4D7C00509231 /* ADJLogger.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 96E5E37318BBB48A008E7B30 /* ADJLogger.h */; }; + 0AB1C9BC27DD4D7C00509231 /* ADJEvent.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9609BC6819EEA55800E02303 /* ADJEvent.h */; }; + 0AB1C9BD27DD4D7C00509231 /* ADJAttribution.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 969952D01A01309200928462 /* ADJAttribution.h */; }; + 0AB1C9BE27DD4D7C00509231 /* ADJConfig.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 960A8BB71A029A8000F2BB95 /* ADJConfig.h */; }; + 0AB1C9BF27DD4D7C00509231 /* ADJSessionSuccess.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 968173811C3C2D07002AE1DE /* ADJSessionSuccess.h */; }; + 0AB1C9C027DD4D7C00509231 /* ADJSessionFailure.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 968173851C3C2D36002AE1DE /* ADJSessionFailure.h */; }; + 0AB1C9C127DD4D7C00509231 /* ADJEventSuccess.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9601CAE21C74B70600670879 /* ADJEventSuccess.h */; }; + 0AB1C9C227DD4D7C00509231 /* ADJEventFailure.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9601CAE61C74BAAE00670879 /* ADJEventFailure.h */; }; + 0AB1C9C327DD4D7C00509231 /* ADJSubscription.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9D2F23E02447CE5C00B7CA90 /* ADJSubscription.h */; }; + 0AB1C9C427DD4D7C00509231 /* ADJThirdPartySharing.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9D651BF425B25A64006D69D6 /* ADJThirdPartySharing.h */; }; + 0AB1C9C527DD4D7C00509231 /* ADJAdRevenue.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9D3A2ABD2625BEB800BD6E44 /* ADJAdRevenue.h */; }; + 0AB1C9C627DD4D7C00509231 /* ADJLinkResolution.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 6FAB784A2636DC0E00773869 /* ADJLinkResolution.h */; }; + 0AB1C9F727DD5B5100509231 /* ModuleMap in Resources */ = {isa = PBXBuildFile; fileRef = 0AB1C9F627DD5B5100509231 /* ModuleMap */; }; + 0AB1CA2A27DF462200509231 /* AdjustSdkTv.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 0AB1CA2727DF462200509231 /* AdjustSdkTv.h */; }; + 0AB1CA2F27DF49CB00509231 /* NSString+ADJAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 96CD2BDD1A13BFC600A40AFB /* NSString+ADJAdditions.m */; }; + 0AB1CA3027DF49CB00509231 /* NSData+ADJAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 96C93DF41AC47F2E00B53F56 /* NSData+ADJAdditions.m */; }; + 0AB1CA3127DF49CB00509231 /* NSNumber+ADJAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DF381A8260E990B0033F5A1 /* NSNumber+ADJAdditions.m */; }; + 0AB1CA3227DF49CB00509231 /* Adjust.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E34D18BBB48A008E7B30 /* Adjust.m */; }; + 0AB1CA3327DF49CB00509231 /* ADJActivityHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36318BBB48A008E7B30 /* ADJActivityHandler.m */; }; + 0AB1CA3427DF49CC00509231 /* ADJActivityKind.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36518BBB48A008E7B30 /* ADJActivityKind.m */; }; + 0AB1CA3527DF49CC00509231 /* ADJActivityPackage.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36718BBB48A008E7B30 /* ADJActivityPackage.m */; }; + 0AB1CA3627DF49CC00509231 /* ADJActivityState.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36918BBB48A008E7B30 /* ADJActivityState.m */; }; + 0AB1CA3727DF49CC00509231 /* ADJAdjustFactory.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37218BBB48A008E7B30 /* ADJAdjustFactory.m */; }; + 0AB1CA3827DF49CC00509231 /* ADJLogger.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37418BBB48A008E7B30 /* ADJLogger.m */; }; + 0AB1CA3927DF49CC00509231 /* ADJPackageBuilder.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37618BBB48A008E7B30 /* ADJPackageBuilder.m */; }; + 0AB1CA3A27DF49CC00509231 /* ADJPackageParams.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DF92D822630ED02000FC3FC /* ADJPackageParams.m */; }; + 0AB1CA3B27DF49CC00509231 /* ADJPackageHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37818BBB48A008E7B30 /* ADJPackageHandler.m */; }; + 0AB1CA3C27DF49CC00509231 /* ADJRequestHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37A18BBB48A008E7B30 /* ADJRequestHandler.m */; }; + 0AB1CA3D27DF49CC00509231 /* ADJUtil.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E38018BBB48A008E7B30 /* ADJUtil.m */; }; + 0AB1CA3E27DF49CC00509231 /* ADJEvent.m in Sources */ = {isa = PBXBuildFile; fileRef = 9609BC6919EEA55800E02303 /* ADJEvent.m */; }; + 0AB1CA3F27DF49CC00509231 /* ADJAttributionHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 969952CE1A012F5300928462 /* ADJAttributionHandler.m */; }; + 0AB1CA4027DF49CC00509231 /* ADJAttribution.m in Sources */ = {isa = PBXBuildFile; fileRef = 969952D11A01309200928462 /* ADJAttribution.m */; }; + 0AB1CA4127DF49CC00509231 /* ADJConfig.m in Sources */ = {isa = PBXBuildFile; fileRef = 960A8BB81A029A8000F2BB95 /* ADJConfig.m */; }; + 0AB1CA4227DF49CC00509231 /* ADJTimerOnce.m in Sources */ = {isa = PBXBuildFile; fileRef = 96854A581B1F2779002B2874 /* ADJTimerOnce.m */; }; + 0AB1CA4327DF49CC00509231 /* ADJTimerCycle.m in Sources */ = {isa = PBXBuildFile; fileRef = 96854A5E1B1F278C002B2874 /* ADJTimerCycle.m */; }; + 0AB1CA4427DF49CC00509231 /* ADJResponseData.m in Sources */ = {isa = PBXBuildFile; fileRef = 96FCC5371C186426007BBFE1 /* ADJResponseData.m */; }; + 0AB1CA4527DF49CC00509231 /* ADJSessionSuccess.m in Sources */ = {isa = PBXBuildFile; fileRef = 968173821C3C2D07002AE1DE /* ADJSessionSuccess.m */; }; + 0AB1CA4627DF49CC00509231 /* ADJSessionFailure.m in Sources */ = {isa = PBXBuildFile; fileRef = 968173861C3C2D36002AE1DE /* ADJSessionFailure.m */; }; + 0AB1CA4727DF49CC00509231 /* ADJEventSuccess.m in Sources */ = {isa = PBXBuildFile; fileRef = 9601CAE31C74B70600670879 /* ADJEventSuccess.m */; }; + 0AB1CA4827DF49CC00509231 /* ADJEventFailure.m in Sources */ = {isa = PBXBuildFile; fileRef = 9601CAE71C74BAAE00670879 /* ADJEventFailure.m */; }; + 0AB1CA4927DF49CC00509231 /* ADJBackoffStrategy.m in Sources */ = {isa = PBXBuildFile; fileRef = 965B7F2F1CC78F6600098639 /* ADJBackoffStrategy.m */; }; + 0AB1CA4A27DF49CC00509231 /* ADJSdkClickHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96164D711CC8FA73009431AB /* ADJSdkClickHandler.m */; }; + 0AB1CA4B27DF49CC00509231 /* ADJSessionParameters.m in Sources */ = {isa = PBXBuildFile; fileRef = 96B6710F1D788EEC0090A023 /* ADJSessionParameters.m */; }; + 0AB1CA4C27DF49CC00509231 /* ADJUserDefaults.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DD0E9AD1F44690B00B2A759 /* ADJUserDefaults.m */; }; + 0AB1CA4D27DF49CC00509231 /* ADJSubscription.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D2F23E12447CE5C00B7CA90 /* ADJSubscription.m */; }; + 0AB1CA4E27DF49CC00509231 /* ADJUrlStrategy.m in Sources */ = {isa = PBXBuildFile; fileRef = 6FBEE8F224E2C26F00FEF3F1 /* ADJUrlStrategy.m */; }; + 0AB1CA4F27DF49CC00509231 /* ADJThirdPartySharing.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D651BE125B25A64006D69D6 /* ADJThirdPartySharing.m */; }; + 0AB1CA5027DF49CC00509231 /* ADJAdRevenue.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D3A2AAA2625BEB800BD6E44 /* ADJAdRevenue.m */; }; + 0AB1CA5127DF49CC00509231 /* ADJLinkResolution.m in Sources */ = {isa = PBXBuildFile; fileRef = 6FAB784B2636DC0E00773869 /* ADJLinkResolution.m */; }; + 0AB1CA5227DF4A2B00509231 /* Adjust.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 96E5E34C18BBB48A008E7B30 /* Adjust.h */; }; + 0AB1CA5327DF4A2B00509231 /* ADJLogger.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 96E5E37318BBB48A008E7B30 /* ADJLogger.h */; }; + 0AB1CA5427DF4A2B00509231 /* ADJEvent.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9609BC6819EEA55800E02303 /* ADJEvent.h */; }; + 0AB1CA5527DF4A2B00509231 /* ADJAttribution.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 969952D01A01309200928462 /* ADJAttribution.h */; }; + 0AB1CA5627DF4A2B00509231 /* ADJConfig.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 960A8BB71A029A8000F2BB95 /* ADJConfig.h */; }; + 0AB1CA5727DF4A2B00509231 /* ADJSessionSuccess.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 968173811C3C2D07002AE1DE /* ADJSessionSuccess.h */; }; + 0AB1CA5827DF4A2B00509231 /* ADJSessionFailure.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 968173851C3C2D36002AE1DE /* ADJSessionFailure.h */; }; + 0AB1CA5927DF4A2B00509231 /* ADJEventSuccess.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9601CAE21C74B70600670879 /* ADJEventSuccess.h */; }; + 0AB1CA5A27DF4A2B00509231 /* ADJEventFailure.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9601CAE61C74BAAE00670879 /* ADJEventFailure.h */; }; + 0AB1CA5B27DF4A2B00509231 /* ADJSubscription.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9D2F23E02447CE5C00B7CA90 /* ADJSubscription.h */; }; + 0AB1CA5C27DF4A2B00509231 /* ADJThirdPartySharing.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9D651BF425B25A64006D69D6 /* ADJThirdPartySharing.h */; }; + 0AB1CA5D27DF4A2B00509231 /* ADJAdRevenue.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9D3A2ABD2625BEB800BD6E44 /* ADJAdRevenue.h */; }; + 0AB1CA5E27DF4A2B00509231 /* ADJLinkResolution.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 6FAB784A2636DC0E00773869 /* ADJLinkResolution.h */; }; + 0AB1CA6D27DF5D3200509231 /* AdjustSdkIm.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 0AB1CA6A27DF5D3200509231 /* AdjustSdkIm.h */; }; + 0AB1CA7227DF61F200509231 /* NSString+ADJAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 96CD2BDD1A13BFC600A40AFB /* NSString+ADJAdditions.m */; }; + 0AB1CA7327DF61F200509231 /* NSData+ADJAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 96C93DF41AC47F2E00B53F56 /* NSData+ADJAdditions.m */; }; + 0AB1CA7427DF61F200509231 /* NSNumber+ADJAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DF381A8260E990B0033F5A1 /* NSNumber+ADJAdditions.m */; }; + 0AB1CA7527DF61F200509231 /* Adjust.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E34D18BBB48A008E7B30 /* Adjust.m */; }; + 0AB1CA7627DF61F200509231 /* ADJActivityHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36318BBB48A008E7B30 /* ADJActivityHandler.m */; }; + 0AB1CA7727DF61F200509231 /* ADJActivityKind.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36518BBB48A008E7B30 /* ADJActivityKind.m */; }; + 0AB1CA7827DF61F200509231 /* ADJActivityPackage.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36718BBB48A008E7B30 /* ADJActivityPackage.m */; }; + 0AB1CA7927DF61F200509231 /* ADJActivityState.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36918BBB48A008E7B30 /* ADJActivityState.m */; }; + 0AB1CA7A27DF61F200509231 /* ADJAdjustFactory.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37218BBB48A008E7B30 /* ADJAdjustFactory.m */; }; + 0AB1CA7B27DF61F200509231 /* ADJLogger.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37418BBB48A008E7B30 /* ADJLogger.m */; }; + 0AB1CA7C27DF61F200509231 /* ADJPackageBuilder.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37618BBB48A008E7B30 /* ADJPackageBuilder.m */; }; + 0AB1CA7D27DF61F200509231 /* ADJPackageParams.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DF92D822630ED02000FC3FC /* ADJPackageParams.m */; }; + 0AB1CA7E27DF61F200509231 /* ADJPackageHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37818BBB48A008E7B30 /* ADJPackageHandler.m */; }; + 0AB1CA7F27DF61F200509231 /* ADJRequestHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37A18BBB48A008E7B30 /* ADJRequestHandler.m */; }; + 0AB1CA8027DF61F200509231 /* ADJUtil.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E38018BBB48A008E7B30 /* ADJUtil.m */; }; + 0AB1CA8127DF61F200509231 /* ADJEvent.m in Sources */ = {isa = PBXBuildFile; fileRef = 9609BC6919EEA55800E02303 /* ADJEvent.m */; }; + 0AB1CA8227DF61F200509231 /* ADJAttributionHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 969952CE1A012F5300928462 /* ADJAttributionHandler.m */; }; + 0AB1CA8327DF61F200509231 /* ADJAttribution.m in Sources */ = {isa = PBXBuildFile; fileRef = 969952D11A01309200928462 /* ADJAttribution.m */; }; + 0AB1CA8427DF61F200509231 /* ADJConfig.m in Sources */ = {isa = PBXBuildFile; fileRef = 960A8BB81A029A8000F2BB95 /* ADJConfig.m */; }; + 0AB1CA8527DF61F200509231 /* ADJTimerOnce.m in Sources */ = {isa = PBXBuildFile; fileRef = 96854A581B1F2779002B2874 /* ADJTimerOnce.m */; }; + 0AB1CA8627DF61F200509231 /* ADJTimerCycle.m in Sources */ = {isa = PBXBuildFile; fileRef = 96854A5E1B1F278C002B2874 /* ADJTimerCycle.m */; }; + 0AB1CA8727DF61F200509231 /* ADJResponseData.m in Sources */ = {isa = PBXBuildFile; fileRef = 96FCC5371C186426007BBFE1 /* ADJResponseData.m */; }; + 0AB1CA8827DF61F200509231 /* ADJSessionSuccess.m in Sources */ = {isa = PBXBuildFile; fileRef = 968173821C3C2D07002AE1DE /* ADJSessionSuccess.m */; }; + 0AB1CA8927DF61F200509231 /* ADJSessionFailure.m in Sources */ = {isa = PBXBuildFile; fileRef = 968173861C3C2D36002AE1DE /* ADJSessionFailure.m */; }; + 0AB1CA8A27DF61F200509231 /* ADJEventSuccess.m in Sources */ = {isa = PBXBuildFile; fileRef = 9601CAE31C74B70600670879 /* ADJEventSuccess.m */; }; + 0AB1CA8B27DF61F200509231 /* ADJEventFailure.m in Sources */ = {isa = PBXBuildFile; fileRef = 9601CAE71C74BAAE00670879 /* ADJEventFailure.m */; }; + 0AB1CA8C27DF61F200509231 /* ADJBackoffStrategy.m in Sources */ = {isa = PBXBuildFile; fileRef = 965B7F2F1CC78F6600098639 /* ADJBackoffStrategy.m */; }; + 0AB1CA8D27DF61F200509231 /* ADJSdkClickHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96164D711CC8FA73009431AB /* ADJSdkClickHandler.m */; }; + 0AB1CA8E27DF61F200509231 /* ADJSessionParameters.m in Sources */ = {isa = PBXBuildFile; fileRef = 96B6710F1D788EEC0090A023 /* ADJSessionParameters.m */; }; + 0AB1CA8F27DF61F200509231 /* ADJUserDefaults.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DD0E9AD1F44690B00B2A759 /* ADJUserDefaults.m */; }; + 0AB1CA9027DF61F200509231 /* ADJSubscription.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D2F23E12447CE5C00B7CA90 /* ADJSubscription.m */; }; + 0AB1CA9127DF61F200509231 /* ADJUrlStrategy.m in Sources */ = {isa = PBXBuildFile; fileRef = 6FBEE8F224E2C26F00FEF3F1 /* ADJUrlStrategy.m */; }; + 0AB1CA9227DF61F200509231 /* ADJThirdPartySharing.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D651BE125B25A64006D69D6 /* ADJThirdPartySharing.m */; }; + 0AB1CA9327DF61F200509231 /* ADJAdRevenue.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D3A2AAA2625BEB800BD6E44 /* ADJAdRevenue.m */; }; + 0AB1CA9427DF61F200509231 /* ADJLinkResolution.m in Sources */ = {isa = PBXBuildFile; fileRef = 6FAB784B2636DC0E00773869 /* ADJLinkResolution.m */; }; + 0AB1CA9527DF621D00509231 /* Adjust.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 96E5E34C18BBB48A008E7B30 /* Adjust.h */; }; + 0AB1CA9627DF621D00509231 /* ADJLogger.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 96E5E37318BBB48A008E7B30 /* ADJLogger.h */; }; + 0AB1CA9727DF621D00509231 /* ADJEvent.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9609BC6819EEA55800E02303 /* ADJEvent.h */; }; + 0AB1CA9827DF621D00509231 /* ADJConfig.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 960A8BB71A029A8000F2BB95 /* ADJConfig.h */; }; + 0AB1CA9927DF621D00509231 /* ADJSessionSuccess.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 968173811C3C2D07002AE1DE /* ADJSessionSuccess.h */; }; + 0AB1CA9A27DF621D00509231 /* ADJSessionFailure.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 968173851C3C2D36002AE1DE /* ADJSessionFailure.h */; }; + 0AB1CA9B27DF621D00509231 /* ADJEventSuccess.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9601CAE21C74B70600670879 /* ADJEventSuccess.h */; }; + 0AB1CA9C27DF621D00509231 /* ADJEventFailure.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9601CAE61C74BAAE00670879 /* ADJEventFailure.h */; }; + 0AB1CA9D27DF621D00509231 /* ADJSubscription.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9D2F23E02447CE5C00B7CA90 /* ADJSubscription.h */; }; + 0AB1CA9E27DF621D00509231 /* ADJThirdPartySharing.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9D651BF425B25A64006D69D6 /* ADJThirdPartySharing.h */; }; + 0AB1CA9F27DF621D00509231 /* ADJAdRevenue.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9D3A2ABD2625BEB800BD6E44 /* ADJAdRevenue.h */; }; + 0AB1CAA027DF621D00509231 /* ADJLinkResolution.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 6FAB784A2636DC0E00773869 /* ADJLinkResolution.h */; }; + 0AB1CAA127DF626000509231 /* ADJAttribution.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 969952D01A01309200928462 /* ADJAttribution.h */; }; + 0AB1CADA27DF671300509231 /* AdjustSdkWebBridge.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 0AB1CAD727DF671300509231 /* AdjustSdkWebBridge.h */; }; + 0AB1CB0927DF68C100509231 /* NSString+ADJAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 96CD2BDD1A13BFC600A40AFB /* NSString+ADJAdditions.m */; }; + 0AB1CB0A27DF68C100509231 /* NSData+ADJAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 96C93DF41AC47F2E00B53F56 /* NSData+ADJAdditions.m */; }; + 0AB1CB0B27DF68C100509231 /* NSNumber+ADJAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DF381A8260E990B0033F5A1 /* NSNumber+ADJAdditions.m */; }; + 0AB1CB0C27DF68C100509231 /* Adjust.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E34D18BBB48A008E7B30 /* Adjust.m */; }; + 0AB1CB0D27DF68C100509231 /* ADJActivityHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36318BBB48A008E7B30 /* ADJActivityHandler.m */; }; + 0AB1CB0E27DF68C100509231 /* ADJActivityKind.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36518BBB48A008E7B30 /* ADJActivityKind.m */; }; + 0AB1CB0F27DF68C100509231 /* ADJActivityPackage.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36718BBB48A008E7B30 /* ADJActivityPackage.m */; }; + 0AB1CB1027DF68C100509231 /* ADJActivityState.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E36918BBB48A008E7B30 /* ADJActivityState.m */; }; + 0AB1CB1127DF68C100509231 /* ADJAdjustFactory.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37218BBB48A008E7B30 /* ADJAdjustFactory.m */; }; + 0AB1CB1227DF68C100509231 /* ADJLogger.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37418BBB48A008E7B30 /* ADJLogger.m */; }; + 0AB1CB1327DF68C100509231 /* ADJPackageBuilder.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37618BBB48A008E7B30 /* ADJPackageBuilder.m */; }; + 0AB1CB1427DF68C100509231 /* ADJPackageParams.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DF92D822630ED02000FC3FC /* ADJPackageParams.m */; }; + 0AB1CB1527DF68C100509231 /* ADJPackageHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37818BBB48A008E7B30 /* ADJPackageHandler.m */; }; + 0AB1CB1627DF68C100509231 /* ADJRequestHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E37A18BBB48A008E7B30 /* ADJRequestHandler.m */; }; + 0AB1CB1727DF68C100509231 /* ADJUtil.m in Sources */ = {isa = PBXBuildFile; fileRef = 96E5E38018BBB48A008E7B30 /* ADJUtil.m */; }; + 0AB1CB1827DF68C100509231 /* ADJEvent.m in Sources */ = {isa = PBXBuildFile; fileRef = 9609BC6919EEA55800E02303 /* ADJEvent.m */; }; + 0AB1CB1927DF68C100509231 /* ADJAttributionHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 969952CE1A012F5300928462 /* ADJAttributionHandler.m */; }; + 0AB1CB1A27DF68C100509231 /* ADJAttribution.m in Sources */ = {isa = PBXBuildFile; fileRef = 969952D11A01309200928462 /* ADJAttribution.m */; }; + 0AB1CB1B27DF68C100509231 /* ADJConfig.m in Sources */ = {isa = PBXBuildFile; fileRef = 960A8BB81A029A8000F2BB95 /* ADJConfig.m */; }; + 0AB1CB1C27DF68C100509231 /* ADJTimerOnce.m in Sources */ = {isa = PBXBuildFile; fileRef = 96854A581B1F2779002B2874 /* ADJTimerOnce.m */; }; + 0AB1CB1D27DF68C100509231 /* ADJTimerCycle.m in Sources */ = {isa = PBXBuildFile; fileRef = 96854A5E1B1F278C002B2874 /* ADJTimerCycle.m */; }; + 0AB1CB1E27DF68C100509231 /* ADJResponseData.m in Sources */ = {isa = PBXBuildFile; fileRef = 96FCC5371C186426007BBFE1 /* ADJResponseData.m */; }; + 0AB1CB1F27DF68C100509231 /* ADJSessionSuccess.m in Sources */ = {isa = PBXBuildFile; fileRef = 968173821C3C2D07002AE1DE /* ADJSessionSuccess.m */; }; + 0AB1CB2027DF68C100509231 /* ADJSessionFailure.m in Sources */ = {isa = PBXBuildFile; fileRef = 968173861C3C2D36002AE1DE /* ADJSessionFailure.m */; }; + 0AB1CB2127DF68C100509231 /* ADJEventSuccess.m in Sources */ = {isa = PBXBuildFile; fileRef = 9601CAE31C74B70600670879 /* ADJEventSuccess.m */; }; + 0AB1CB2227DF68C100509231 /* ADJEventFailure.m in Sources */ = {isa = PBXBuildFile; fileRef = 9601CAE71C74BAAE00670879 /* ADJEventFailure.m */; }; + 0AB1CB2327DF68C100509231 /* ADJBackoffStrategy.m in Sources */ = {isa = PBXBuildFile; fileRef = 965B7F2F1CC78F6600098639 /* ADJBackoffStrategy.m */; }; + 0AB1CB2427DF68C100509231 /* ADJSdkClickHandler.m in Sources */ = {isa = PBXBuildFile; fileRef = 96164D711CC8FA73009431AB /* ADJSdkClickHandler.m */; }; + 0AB1CB2527DF68C100509231 /* ADJSessionParameters.m in Sources */ = {isa = PBXBuildFile; fileRef = 96B6710F1D788EEC0090A023 /* ADJSessionParameters.m */; }; + 0AB1CB2627DF68C100509231 /* ADJUserDefaults.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DD0E9AD1F44690B00B2A759 /* ADJUserDefaults.m */; }; + 0AB1CB2727DF68C100509231 /* ADJSubscription.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D2F23E12447CE5C00B7CA90 /* ADJSubscription.m */; }; + 0AB1CB2827DF68C100509231 /* ADJUrlStrategy.m in Sources */ = {isa = PBXBuildFile; fileRef = 6FBEE8F224E2C26F00FEF3F1 /* ADJUrlStrategy.m */; }; + 0AB1CB2927DF68C100509231 /* ADJThirdPartySharing.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D651BE125B25A64006D69D6 /* ADJThirdPartySharing.m */; }; + 0AB1CB2A27DF68C100509231 /* ADJAdRevenue.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D3A2AAA2625BEB800BD6E44 /* ADJAdRevenue.m */; }; + 0AB1CB2B27DF68C100509231 /* ADJLinkResolution.m in Sources */ = {isa = PBXBuildFile; fileRef = 6FAB784B2636DC0E00773869 /* ADJLinkResolution.m */; }; + 0AB1CB2C27DF68DB00509231 /* AdjustBridge.m in Sources */ = {isa = PBXBuildFile; fileRef = 9648C5F61CD1770300A3B049 /* AdjustBridge.m */; }; + 0AB1CB2D27DF68DB00509231 /* AdjustBridgeRegister.m in Sources */ = {isa = PBXBuildFile; fileRef = 968595ED1D0B25970011CA2B /* AdjustBridgeRegister.m */; }; + 0AB1CB2E27DF68DB00509231 /* WebViewJavascriptBridge_JS.m in Sources */ = {isa = PBXBuildFile; fileRef = 9648C5E91CD1765E00A3B049 /* WebViewJavascriptBridge_JS.m */; }; + 0AB1CB2F27DF68DB00509231 /* WebViewJavascriptBridgeBase.m in Sources */ = {isa = PBXBuildFile; fileRef = 9648C5EB1CD1765E00A3B049 /* WebViewJavascriptBridgeBase.m */; }; + 0AB1CB3027DF68DB00509231 /* WKWebViewJavascriptBridge.m in Sources */ = {isa = PBXBuildFile; fileRef = 9648C5ED1CD1765E00A3B049 /* WKWebViewJavascriptBridge.m */; }; + 0AB1CB3127DF699E00509231 /* Adjust.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 96E5E34C18BBB48A008E7B30 /* Adjust.h */; }; + 0AB1CB3227DF699E00509231 /* ADJLogger.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 96E5E37318BBB48A008E7B30 /* ADJLogger.h */; }; + 0AB1CB3327DF699E00509231 /* ADJEvent.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9609BC6819EEA55800E02303 /* ADJEvent.h */; }; + 0AB1CB3427DF699E00509231 /* ADJAttribution.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 969952D01A01309200928462 /* ADJAttribution.h */; }; + 0AB1CB3527DF699E00509231 /* ADJConfig.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 960A8BB71A029A8000F2BB95 /* ADJConfig.h */; }; + 0AB1CB3627DF699E00509231 /* ADJSessionSuccess.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 968173811C3C2D07002AE1DE /* ADJSessionSuccess.h */; }; + 0AB1CB3727DF699E00509231 /* ADJSessionFailure.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 968173851C3C2D36002AE1DE /* ADJSessionFailure.h */; }; + 0AB1CB3827DF699E00509231 /* ADJEventSuccess.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9601CAE21C74B70600670879 /* ADJEventSuccess.h */; }; + 0AB1CB3927DF699E00509231 /* ADJEventFailure.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9601CAE61C74BAAE00670879 /* ADJEventFailure.h */; }; + 0AB1CB3A27DF699E00509231 /* ADJSubscription.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9D2F23E02447CE5C00B7CA90 /* ADJSubscription.h */; }; + 0AB1CB3B27DF699E00509231 /* ADJThirdPartySharing.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9D651BF425B25A64006D69D6 /* ADJThirdPartySharing.h */; }; + 0AB1CB3C27DF699E00509231 /* ADJAdRevenue.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9D3A2ABD2625BEB800BD6E44 /* ADJAdRevenue.h */; }; + 0AB1CB3D27DF699E00509231 /* ADJLinkResolution.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 6FAB784A2636DC0E00773869 /* ADJLinkResolution.h */; }; + 0AB1CB3E27DF69B700509231 /* AdjustBridge.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9648C5F51CD1770300A3B049 /* AdjustBridge.h */; }; + 0AB1CB3F27DF69B700509231 /* AdjustBridgeRegister.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 968595EC1D0B25970011CA2B /* AdjustBridgeRegister.h */; }; + 0AB1CB4027DF69B700509231 /* WebViewJavascriptBridge_JS.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9648C5E81CD1765E00A3B049 /* WebViewJavascriptBridge_JS.h */; }; + 0AB1CB4127DF69B700509231 /* WebViewJavascriptBridgeBase.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9648C5EA1CD1765E00A3B049 /* WebViewJavascriptBridgeBase.h */; }; + 0AB1CB4227DF69B700509231 /* WKWebViewJavascriptBridge.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9648C5EC1CD1765E00A3B049 /* WKWebViewJavascriptBridge.h */; }; 2067002A1F18BDC700B4FDE1 /* CoreTelephony.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9601C19C1A31DD7F00A9AE21 /* CoreTelephony.framework */; settings = {ATTRIBUTES = (Weak, ); }; }; 6F84512425B1B1380004C7C0 /* ADJThirdPartySharing.h in Headers */ = {isa = PBXBuildFile; fileRef = 6F84511025B1B1380004C7C0 /* ADJThirdPartySharing.h */; settings = {ATTRIBUTES = (Public, ); }; }; 6F84512525B1B1380004C7C0 /* ADJThirdPartySharing.m in Sources */ = {isa = PBXBuildFile; fileRef = 6F84512325B1B1380004C7C0 /* ADJThirdPartySharing.m */; }; @@ -584,6 +791,103 @@ /* End PBXContainerItemProxy section */ /* Begin PBXCopyFilesBuildPhase section */ + 0AB1C96F27DD450D00509231 /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = "include/$(PRODUCT_NAME)"; + dstSubfolderSpec = 16; + files = ( + 0AB1C97627DD450D00509231 /* AdjustSdk.h in CopyFiles */, + 0AB1C9BA27DD4D7C00509231 /* Adjust.h in CopyFiles */, + 0AB1C9BB27DD4D7C00509231 /* ADJLogger.h in CopyFiles */, + 0AB1C9BC27DD4D7C00509231 /* ADJEvent.h in CopyFiles */, + 0AB1C9BD27DD4D7C00509231 /* ADJAttribution.h in CopyFiles */, + 0AB1C9BE27DD4D7C00509231 /* ADJConfig.h in CopyFiles */, + 0AB1C9BF27DD4D7C00509231 /* ADJSessionSuccess.h in CopyFiles */, + 0AB1C9C027DD4D7C00509231 /* ADJSessionFailure.h in CopyFiles */, + 0AB1C9C127DD4D7C00509231 /* ADJEventSuccess.h in CopyFiles */, + 0AB1C9C227DD4D7C00509231 /* ADJEventFailure.h in CopyFiles */, + 0AB1C9C327DD4D7C00509231 /* ADJSubscription.h in CopyFiles */, + 0AB1C9C427DD4D7C00509231 /* ADJThirdPartySharing.h in CopyFiles */, + 0AB1C9C527DD4D7C00509231 /* ADJAdRevenue.h in CopyFiles */, + 0AB1C9C627DD4D7C00509231 /* ADJLinkResolution.h in CopyFiles */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 0AB1CA2327DF462200509231 /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = "include/$(PRODUCT_NAME)"; + dstSubfolderSpec = 16; + files = ( + 0AB1CA2A27DF462200509231 /* AdjustSdkTv.h in CopyFiles */, + 0AB1CA5227DF4A2B00509231 /* Adjust.h in CopyFiles */, + 0AB1CA5327DF4A2B00509231 /* ADJLogger.h in CopyFiles */, + 0AB1CA5427DF4A2B00509231 /* ADJEvent.h in CopyFiles */, + 0AB1CA5527DF4A2B00509231 /* ADJAttribution.h in CopyFiles */, + 0AB1CA5627DF4A2B00509231 /* ADJConfig.h in CopyFiles */, + 0AB1CA5727DF4A2B00509231 /* ADJSessionSuccess.h in CopyFiles */, + 0AB1CA5827DF4A2B00509231 /* ADJSessionFailure.h in CopyFiles */, + 0AB1CA5927DF4A2B00509231 /* ADJEventSuccess.h in CopyFiles */, + 0AB1CA5A27DF4A2B00509231 /* ADJEventFailure.h in CopyFiles */, + 0AB1CA5B27DF4A2B00509231 /* ADJSubscription.h in CopyFiles */, + 0AB1CA5C27DF4A2B00509231 /* ADJThirdPartySharing.h in CopyFiles */, + 0AB1CA5D27DF4A2B00509231 /* ADJAdRevenue.h in CopyFiles */, + 0AB1CA5E27DF4A2B00509231 /* ADJLinkResolution.h in CopyFiles */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 0AB1CA6627DF5D3200509231 /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = "include/$(PRODUCT_NAME)"; + dstSubfolderSpec = 16; + files = ( + 0AB1CA6D27DF5D3200509231 /* AdjustSdkIm.h in CopyFiles */, + 0AB1CA9527DF621D00509231 /* Adjust.h in CopyFiles */, + 0AB1CA9627DF621D00509231 /* ADJLogger.h in CopyFiles */, + 0AB1CA9727DF621D00509231 /* ADJEvent.h in CopyFiles */, + 0AB1CA9827DF621D00509231 /* ADJConfig.h in CopyFiles */, + 0AB1CA9927DF621D00509231 /* ADJSessionSuccess.h in CopyFiles */, + 0AB1CA9A27DF621D00509231 /* ADJSessionFailure.h in CopyFiles */, + 0AB1CA9B27DF621D00509231 /* ADJEventSuccess.h in CopyFiles */, + 0AB1CA9C27DF621D00509231 /* ADJEventFailure.h in CopyFiles */, + 0AB1CA9D27DF621D00509231 /* ADJSubscription.h in CopyFiles */, + 0AB1CAA127DF626000509231 /* ADJAttribution.h in CopyFiles */, + 0AB1CA9E27DF621D00509231 /* ADJThirdPartySharing.h in CopyFiles */, + 0AB1CA9F27DF621D00509231 /* ADJAdRevenue.h in CopyFiles */, + 0AB1CAA027DF621D00509231 /* ADJLinkResolution.h in CopyFiles */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 0AB1CAD327DF671300509231 /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = "include/$(PRODUCT_NAME)"; + dstSubfolderSpec = 16; + files = ( + 0AB1CADA27DF671300509231 /* AdjustSdkWebBridge.h in CopyFiles */, + 0AB1CB3127DF699E00509231 /* Adjust.h in CopyFiles */, + 0AB1CB3227DF699E00509231 /* ADJLogger.h in CopyFiles */, + 0AB1CB3327DF699E00509231 /* ADJEvent.h in CopyFiles */, + 0AB1CB3427DF699E00509231 /* ADJAttribution.h in CopyFiles */, + 0AB1CB3527DF699E00509231 /* ADJConfig.h in CopyFiles */, + 0AB1CB3627DF699E00509231 /* ADJSessionSuccess.h in CopyFiles */, + 0AB1CB3727DF699E00509231 /* ADJSessionFailure.h in CopyFiles */, + 0AB1CB3827DF699E00509231 /* ADJEventSuccess.h in CopyFiles */, + 0AB1CB3927DF699E00509231 /* ADJEventFailure.h in CopyFiles */, + 0AB1CB3A27DF699E00509231 /* ADJSubscription.h in CopyFiles */, + 0AB1CB3B27DF699E00509231 /* ADJThirdPartySharing.h in CopyFiles */, + 0AB1CB3C27DF699E00509231 /* ADJAdRevenue.h in CopyFiles */, + 0AB1CB3D27DF699E00509231 /* ADJLinkResolution.h in CopyFiles */, + 0AB1CB3E27DF69B700509231 /* AdjustBridge.h in CopyFiles */, + 0AB1CB3F27DF69B700509231 /* AdjustBridgeRegister.h in CopyFiles */, + 0AB1CB4027DF69B700509231 /* WebViewJavascriptBridge_JS.h in CopyFiles */, + 0AB1CB4127DF69B700509231 /* WebViewJavascriptBridgeBase.h in CopyFiles */, + 0AB1CB4227DF69B700509231 /* WKWebViewJavascriptBridge.h in CopyFiles */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; 9615158D1CD2CB2C0022D336 /* CopyFiles */ = { isa = PBXCopyFilesBuildPhase; buildActionMask = 2147483647; @@ -606,6 +910,19 @@ /* End PBXCopyFilesBuildPhase section */ /* Begin PBXFileReference section */ + 0AB1C97127DD450D00509231 /* libAdjustSdk.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libAdjustSdk.a; sourceTree = BUILT_PRODUCTS_DIR; }; + 0AB1C97327DD450D00509231 /* AdjustSdk.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AdjustSdk.h; sourceTree = ""; }; + 0AB1C9F627DD5B5100509231 /* ModuleMap */ = {isa = PBXFileReference; lastKnownFileType = folder; path = ModuleMap; sourceTree = ""; }; + 0AB1C9F827DD5C2400509231 /* module.modulemap */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.module-map"; path = module.modulemap; sourceTree = ""; }; + 0AB1CA2527DF462200509231 /* libAdjustSdkTv.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libAdjustSdkTv.a; sourceTree = BUILT_PRODUCTS_DIR; }; + 0AB1CA2727DF462200509231 /* AdjustSdkTv.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AdjustSdkTv.h; sourceTree = ""; }; + 0AB1CA2E27DF493500509231 /* module.modulemap */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = "sourcecode.module-map"; path = module.modulemap; sourceTree = ""; }; + 0AB1CA6827DF5D3200509231 /* libAdjustSdkIm.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libAdjustSdkIm.a; sourceTree = BUILT_PRODUCTS_DIR; }; + 0AB1CA6A27DF5D3200509231 /* AdjustSdkIm.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AdjustSdkIm.h; sourceTree = ""; }; + 0AB1CA7127DF5FFE00509231 /* module.modulemap */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = "sourcecode.module-map"; path = module.modulemap; sourceTree = ""; }; + 0AB1CAD527DF671300509231 /* libAdjustSdkWebBridge.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libAdjustSdkWebBridge.a; sourceTree = BUILT_PRODUCTS_DIR; }; + 0AB1CAD727DF671300509231 /* AdjustSdkWebBridge.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AdjustSdkWebBridge.h; sourceTree = ""; }; + 0AB1CB4427DF6C8E00509231 /* module.modulemap */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = "sourcecode.module-map"; path = module.modulemap; sourceTree = ""; }; 52BD7374221C3EDB004F2E87 /* PocketSocket.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = PocketSocket.xcodeproj; path = PocketSocket/PocketSocket.xcodeproj; sourceTree = ""; }; 6F0842182007766700568A31 /* AdjustTestLibrary.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = AdjustTestLibrary.xcodeproj; path = AdjustTestLibrary/AdjustTestLibrary.xcodeproj; sourceTree = ""; }; 6F084240200776A000568A31 /* AdjustTestApp.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = AdjustTestApp.xcodeproj; path = AdjustTestApp/AdjustTestApp.xcodeproj; sourceTree = ""; }; @@ -1064,6 +1381,34 @@ /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ + 0AB1C96E27DD450D00509231 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 0AB1CA2227DF462200509231 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 0AB1CA6527DF5D3200509231 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 0AB1CAD227DF671300509231 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; 9615158C1CD2CB2C0022D336 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; @@ -1137,6 +1482,42 @@ /* End PBXFrameworksBuildPhase section */ /* Begin PBXGroup section */ + 0AB1C97227DD450D00509231 /* AdjustSdkStatic */ = { + isa = PBXGroup; + children = ( + 0AB1C97327DD450D00509231 /* AdjustSdk.h */, + 0AB1C9F827DD5C2400509231 /* module.modulemap */, + ); + path = AdjustSdkStatic; + sourceTree = ""; + }; + 0AB1CA2627DF462200509231 /* AdjustSdkTvStatic */ = { + isa = PBXGroup; + children = ( + 0AB1CA2E27DF493500509231 /* module.modulemap */, + 0AB1CA2727DF462200509231 /* AdjustSdkTv.h */, + ); + path = AdjustSdkTvStatic; + sourceTree = ""; + }; + 0AB1CA6927DF5D3200509231 /* AdjustSdkImStatic */ = { + isa = PBXGroup; + children = ( + 0AB1CA7127DF5FFE00509231 /* module.modulemap */, + 0AB1CA6A27DF5D3200509231 /* AdjustSdkIm.h */, + ); + path = AdjustSdkImStatic; + sourceTree = ""; + }; + 0AB1CAD627DF671300509231 /* AdjustSdkWebBridgeStatic */ = { + isa = PBXGroup; + children = ( + 0AB1CB4427DF6C8E00509231 /* module.modulemap */, + 0AB1CAD727DF671300509231 /* AdjustSdkWebBridge.h */, + ); + path = AdjustSdkWebBridgeStatic; + sourceTree = ""; + }; 52BD7375221C3EDB004F2E87 /* Products */ = { isa = PBXGroup; children = ( @@ -1256,12 +1637,17 @@ children = ( 96E5E34B18BBB48A008E7B30 /* Adjust */, 9DFA37AE1C0F219400782607 /* AdjustSdk */, + 0AB1C97227DD450D00509231 /* AdjustSdkStatic */, 9DE354D32100726300D211C9 /* AdjustSdkIm */, + 0AB1CA6927DF5D3200509231 /* AdjustSdkImStatic */, 9DFB06111D747070006D48FC /* AdjustSdkTv */, + 0AB1CA2627DF462200509231 /* AdjustSdkTvStatic */, 9648C5E41CD1765E00A3B049 /* AdjustBridge */, 9D0E2E03210B570600133B4F /* AdjustSdkWebBridge */, + 0AB1CAD627DF671300509231 /* AdjustSdkWebBridgeStatic */, 96E5E39A18BBB49E008E7B30 /* AdjustTests */, 9D449DAC1E6ED20400E7E80B /* Example Apps */, + 0AB1C9F627DD5B5100509231 /* ModuleMap */, 9679920F18BBAE2800394606 /* Frameworks */, 9679920E18BBAE2800394606 /* Products */, ); @@ -1278,6 +1664,10 @@ 9D7431E61EB9F9B700969F14 /* AdjustExampleTests.app */, 9DE354D22100726300D211C9 /* AdjustSdkIm.framework */, 9D0E2E02210B570600133B4F /* AdjustSdkWebBridge.framework */, + 0AB1C97127DD450D00509231 /* libAdjustSdk.a */, + 0AB1CA2527DF462200509231 /* libAdjustSdkTv.a */, + 0AB1CA6827DF5D3200509231 /* libAdjustSdkIm.a */, + 0AB1CAD527DF671300509231 /* libAdjustSdkWebBridge.a */, ); name = Products; sourceTree = ""; @@ -2117,6 +2507,78 @@ /* End PBXHeadersBuildPhase section */ /* Begin PBXNativeTarget section */ + 0AB1C97027DD450D00509231 /* AdjustSdkStatic */ = { + isa = PBXNativeTarget; + buildConfigurationList = 0AB1C98B27DD450D00509231 /* Build configuration list for PBXNativeTarget "AdjustSdkStatic" */; + buildPhases = ( + 0AB1C96D27DD450D00509231 /* Sources */, + 0AB1C96E27DD450D00509231 /* Frameworks */, + 0AB1C96F27DD450D00509231 /* CopyFiles */, + 0AB1C9C727DD4E6400509231 /* ShellScript */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = AdjustSdkStatic; + productName = AdjustSdkStatic; + productReference = 0AB1C97127DD450D00509231 /* libAdjustSdk.a */; + productType = "com.apple.product-type.library.static"; + }; + 0AB1CA2427DF462200509231 /* AdjustSdkTvStatic */ = { + isa = PBXNativeTarget; + buildConfigurationList = 0AB1CA2B27DF462200509231 /* Build configuration list for PBXNativeTarget "AdjustSdkTvStatic" */; + buildPhases = ( + 0AB1CA2127DF462200509231 /* Sources */, + 0AB1CA2227DF462200509231 /* Frameworks */, + 0AB1CA2327DF462200509231 /* CopyFiles */, + 0AB1CA5F27DF4A4F00509231 /* ShellScript */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = AdjustSdkTvStatic; + productName = AdjustSdkTvStatic; + productReference = 0AB1CA2527DF462200509231 /* libAdjustSdkTv.a */; + productType = "com.apple.product-type.library.static"; + }; + 0AB1CA6727DF5D3200509231 /* AdjustSdkImStatic */ = { + isa = PBXNativeTarget; + buildConfigurationList = 0AB1CA6E27DF5D3200509231 /* Build configuration list for PBXNativeTarget "AdjustSdkImStatic" */; + buildPhases = ( + 0AB1CA6427DF5D3200509231 /* Sources */, + 0AB1CA6527DF5D3200509231 /* Frameworks */, + 0AB1CA6627DF5D3200509231 /* CopyFiles */, + 0AB1CAA227DF62E300509231 /* ShellScript */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = AdjustSdkImStatic; + productName = AdjustSdkImStatic; + productReference = 0AB1CA6827DF5D3200509231 /* libAdjustSdkIm.a */; + productType = "com.apple.product-type.library.static"; + }; + 0AB1CAD427DF671300509231 /* AdjustSdkWebBridgeStatic */ = { + isa = PBXNativeTarget; + buildConfigurationList = 0AB1CADB27DF671300509231 /* Build configuration list for PBXNativeTarget "AdjustSdkWebBridgeStatic" */; + buildPhases = ( + 0AB1CAD127DF671300509231 /* Sources */, + 0AB1CAD227DF671300509231 /* Frameworks */, + 0AB1CAD327DF671300509231 /* CopyFiles */, + 0AB1CB4327DF6C6A00509231 /* ShellScript */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = AdjustSdkWebBridgeStatic; + productName = AdjustSdkWebBridgeStatic; + productReference = 0AB1CAD527DF671300509231 /* libAdjustSdkWebBridge.a */; + productType = "com.apple.product-type.library.static"; + }; 9615158E1CD2CB2C0022D336 /* AdjustBridge */ = { isa = PBXNativeTarget; buildConfigurationList = 9615159E1CD2CB2C0022D336 /* Build configuration list for PBXNativeTarget "AdjustBridge" */; @@ -2233,6 +2695,7 @@ 9DFA37A91C0F219400782607 /* Frameworks */, 9DFA37AA1C0F219400782607 /* Headers */, 9DFA37AB1C0F219400782607 /* Resources */, + 0A1B45AD2819601000C9BC30 /* ShellScript */, ); buildRules = ( ); @@ -2269,6 +2732,18 @@ LastUpgradeCheck = 1250; ORGANIZATIONNAME = "Adjust GmbH"; TargetAttributes = { + 0AB1C97027DD450D00509231 = { + CreatedOnToolsVersion = 13.2.1; + }; + 0AB1CA2427DF462200509231 = { + CreatedOnToolsVersion = 13.2.1; + }; + 0AB1CA6727DF5D3200509231 = { + CreatedOnToolsVersion = 13.2.1; + }; + 0AB1CAD427DF671300509231 = { + CreatedOnToolsVersion = 13.2.1; + }; 9615158E1CD2CB2C0022D336 = { CreatedOnToolsVersion = 7.3.1; }; @@ -2367,6 +2842,10 @@ 9D0E2E01210B570600133B4F /* AdjustSdkWebBridge */, 9679921C18BBAE2800394606 /* AdjustTests */, 9D7431E51EB9F9B700969F14 /* AdjustExampleTests */, + 0AB1C97027DD450D00509231 /* AdjustSdkStatic */, + 0AB1CA2427DF462200509231 /* AdjustSdkTvStatic */, + 0AB1CA6727DF5D3200509231 /* AdjustSdkImStatic */, + 0AB1CAD427DF671300509231 /* AdjustSdkWebBridgeStatic */, ); }; /* End PBXProject section */ @@ -2530,12 +3009,99 @@ isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( + 0AB1C9F727DD5B5100509231 /* ModuleMap in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXResourcesBuildPhase section */ /* Begin PBXShellScriptBuildPhase section */ + 0A1B45AD2819601000C9BC30 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + ); + inputPaths = ( + ); + outputFileListPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = " +"; + }; + 0AB1C9C727DD4E6400509231 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + ); + inputPaths = ( + ); + outputFileListPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "set -e\n\nexport FRAMEWORK_LOCN=\"${BUILT_PRODUCTS_DIR}/static_framework/${PRODUCT_NAME}.framework\"\n\n# Create the path to the real Headers die\nmkdir -p \"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n\n# Create the required symlinks\n/bin/ln -sfh A \"${FRAMEWORK_LOCN}/Versions/Current\"\n/bin/ln -sfh Versions/Current/Headers \"${FRAMEWORK_LOCN}/Headers\"\n/bin/ln -sfh \"Versions/Current/${PRODUCT_NAME}\" \\\n\"${FRAMEWORK_LOCN}/${PRODUCT_NAME}\"\n\n# Copy the public headers into the framework\n/bin/cp -a \"${TARGET_BUILD_DIR}/${PUBLIC_HEADERS_FOLDER_PATH}/\" \\\n\"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n\n\n# Copy the static library into the framework\n/bin/cp -a \"${TARGET_BUILD_DIR}/lib${PRODUCT_NAME}.a\" \\\n\"${FRAMEWORK_LOCN}/Versions/A/${PRODUCT_NAME}\"\n\n# Add module.modulemap to static framework to make Swift users happy.\nmkdir -p \"${FRAMEWORK_LOCN}/Modules\"\ncp -a \"${SRCROOT}/${TARGET_NAME}/module.modulemap\" \"${FRAMEWORK_LOCN}/Modules/module.modulemap\"\n\n# Copy Resulting framework\nmkdir -p \"${SOURCE_ROOT}/sdk_distribution/${TARGET_NAME}/${PLATFORM_NAME}\"\nditto \"${FRAMEWORK_LOCN}\" \"${SOURCE_ROOT}/sdk_distribution/${TARGET_NAME}/${PLATFORM_NAME}/${PRODUCT_NAME}.framework\"\n"; + }; + 0AB1CA5F27DF4A4F00509231 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + ); + inputPaths = ( + ); + outputFileListPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "set -e\n\nexport FRAMEWORK_LOCN=\"${BUILT_PRODUCTS_DIR}/static_framework/${PRODUCT_NAME}.framework\"\n\n# Create the path to the real Headers die\nmkdir -p \"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n\n# Create the required symlinks\n/bin/ln -sfh A \"${FRAMEWORK_LOCN}/Versions/Current\"\n/bin/ln -sfh Versions/Current/Headers \"${FRAMEWORK_LOCN}/Headers\"\n/bin/ln -sfh \"Versions/Current/${PRODUCT_NAME}\" \\\n\"${FRAMEWORK_LOCN}/${PRODUCT_NAME}\"\n\n# Copy the public headers into the framework\n/bin/cp -a \"${TARGET_BUILD_DIR}/${PUBLIC_HEADERS_FOLDER_PATH}/\" \\\n\"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n\n\n# Copy the static library into the framework\n/bin/cp -a \"${TARGET_BUILD_DIR}/lib${PRODUCT_NAME}.a\" \\\n\"${FRAMEWORK_LOCN}/Versions/A/${PRODUCT_NAME}\"\n\n# Add module.modulemap to static framework to make Swift users happy.\nmkdir -p \"${FRAMEWORK_LOCN}/Modules\"\ncp -a \"${SRCROOT}/${TARGET_NAME}/module.modulemap\" \"${FRAMEWORK_LOCN}/Modules/module.modulemap\"\n\n# Copy Resulting framework\nmkdir -p \"${SOURCE_ROOT}/sdk_distribution/${TARGET_NAME}/${PLATFORM_NAME}\"\nditto \"${FRAMEWORK_LOCN}\" \"${SOURCE_ROOT}/sdk_distribution/${TARGET_NAME}/${PLATFORM_NAME}/${PRODUCT_NAME}.framework\"\n"; + }; + 0AB1CAA227DF62E300509231 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + ); + inputPaths = ( + ); + outputFileListPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "set -e\n\nexport FRAMEWORK_LOCN=\"${BUILT_PRODUCTS_DIR}/static_framework/${PRODUCT_NAME}.framework\"\n\n# Create the path to the real Headers die\nmkdir -p \"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n\n# Create the required symlinks\n/bin/ln -sfh A \"${FRAMEWORK_LOCN}/Versions/Current\"\n/bin/ln -sfh Versions/Current/Headers \"${FRAMEWORK_LOCN}/Headers\"\n/bin/ln -sfh \"Versions/Current/${PRODUCT_NAME}\" \\\n\"${FRAMEWORK_LOCN}/${PRODUCT_NAME}\"\n\n# Copy the public headers into the framework\n/bin/cp -a \"${TARGET_BUILD_DIR}/${PUBLIC_HEADERS_FOLDER_PATH}/\" \\\n\"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n\n\n# Copy the static library into the framework\n/bin/cp -a \"${TARGET_BUILD_DIR}/lib${PRODUCT_NAME}.a\" \\\n\"${FRAMEWORK_LOCN}/Versions/A/${PRODUCT_NAME}\"\n\n# Add module.modulemap to static framework to make Swift users happy.\nmkdir -p \"${FRAMEWORK_LOCN}/Modules\"\ncp -a \"${SRCROOT}/${TARGET_NAME}/module.modulemap\" \"${FRAMEWORK_LOCN}/Modules/module.modulemap\"\n\n# Copy Resulting framework\nmkdir -p \"${SOURCE_ROOT}/sdk_distribution/${TARGET_NAME}/${PLATFORM_NAME}\"\nditto \"${FRAMEWORK_LOCN}\" \"${SOURCE_ROOT}/sdk_distribution/${TARGET_NAME}/${PLATFORM_NAME}/${PRODUCT_NAME}.framework\"\n"; + }; + 0AB1CB4327DF6C6A00509231 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + inputFileListPaths = ( + ); + inputPaths = ( + ); + outputFileListPaths = ( + ); + outputPaths = ( + ); + runOnlyForDeploymentPostprocessing = 0; + shellPath = /bin/sh; + shellScript = "set -e\n\nexport FRAMEWORK_LOCN=\"${BUILT_PRODUCTS_DIR}/static_framework/${PRODUCT_NAME}.framework\"\n\n# Create the path to the real Headers die\nmkdir -p \"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n\n# Create the required symlinks\n/bin/ln -sfh A \"${FRAMEWORK_LOCN}/Versions/Current\"\n/bin/ln -sfh Versions/Current/Headers \"${FRAMEWORK_LOCN}/Headers\"\n/bin/ln -sfh \"Versions/Current/${PRODUCT_NAME}\" \\\n\"${FRAMEWORK_LOCN}/${PRODUCT_NAME}\"\n\n# Copy the public headers into the framework\n/bin/cp -a \"${TARGET_BUILD_DIR}/${PUBLIC_HEADERS_FOLDER_PATH}/\" \\\n\"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n\n\n# Copy the static library into the framework\n/bin/cp -a \"${TARGET_BUILD_DIR}/lib${PRODUCT_NAME}.a\" \\\n\"${FRAMEWORK_LOCN}/Versions/A/${PRODUCT_NAME}\"\n\n# Add module.modulemap to static framework to make Swift users happy.\nmkdir -p \"${FRAMEWORK_LOCN}/Modules\"\ncp -a \"${SRCROOT}/${TARGET_NAME}/module.modulemap\" \"${FRAMEWORK_LOCN}/Modules/module.modulemap\"\n\n# Copy Resulting framework\nmkdir -p \"${SOURCE_ROOT}/sdk_distribution/${TARGET_NAME}/${PLATFORM_NAME}\"\nditto \"${FRAMEWORK_LOCN}\" \"${SOURCE_ROOT}/sdk_distribution/${TARGET_NAME}/${PLATFORM_NAME}/${PRODUCT_NAME}.framework\"\n"; + }; 9DE7C9011AE68F68001556E5 /* Build Framework */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; @@ -2548,7 +3114,7 @@ ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "set -e\n\nexport FRAMEWORK_LOCN=\"${BUILT_PRODUCTS_DIR}/Static/${PRODUCT_NAME}Sdk.framework\"\n\n# Create the path to the real Headers die\nmkdir -p \"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n\n# Create the required symlinks\n/bin/ln -sfh A \"${FRAMEWORK_LOCN}/Versions/Current\"\n/bin/ln -sfh Versions/Current/Headers \"${FRAMEWORK_LOCN}/Headers\"\n/bin/ln -sfh \"Versions/Current/${PRODUCT_NAME}Sdk\" \\\n\"${FRAMEWORK_LOCN}/${PRODUCT_NAME}Sdk\"\n\n# Copy the public headers into the framework\n/bin/cp -a \"${TARGET_BUILD_DIR}/${PUBLIC_HEADERS_FOLDER_PATH}/\" \\\n\"${FRAMEWORK_LOCN}/Versions/A/Headers\""; + shellScript = "set -e\n\nexport FRAMEWORK_LOCN=\"${BUILT_PRODUCTS_DIR}/Static/${PRODUCT_NAME}Sdk.framework\"\n\n# Create the path to the real Headers die\nmkdir -p \"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n\n# Create the required symlinks\n/bin/ln -sfh A \"${FRAMEWORK_LOCN}/Versions/Current\"\n/bin/ln -sfh Versions/Current/Headers \"${FRAMEWORK_LOCN}/Headers\"\n/bin/ln -sfh \"Versions/Current/${PRODUCT_NAME}Sdk\" \\\n\"${FRAMEWORK_LOCN}/${PRODUCT_NAME}Sdk\"\n\n# Copy the public headers into the framework\n/bin/cp -a \"${TARGET_BUILD_DIR}/${PUBLIC_HEADERS_FOLDER_PATH}/\" \\\n\"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n"; }; 9DE7C9021AE68FA5001556E5 /* MultiPlatform Build */ = { isa = PBXShellScriptBuildPhase; @@ -2567,6 +3133,179 @@ /* End PBXShellScriptBuildPhase section */ /* Begin PBXSourcesBuildPhase section */ + 0AB1C96D27DD450D00509231 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 0AB1C99727DD4A9500509231 /* NSString+ADJAdditions.m in Sources */, + 0AB1C99827DD4B3100509231 /* NSData+ADJAdditions.m in Sources */, + 0AB1C99927DD4B3100509231 /* NSNumber+ADJAdditions.m in Sources */, + 0AB1C99A27DD4B3100509231 /* Adjust.m in Sources */, + 0AB1C99B27DD4B3100509231 /* ADJActivityHandler.m in Sources */, + 0AB1C99C27DD4B3100509231 /* ADJActivityKind.m in Sources */, + 0AB1C99D27DD4B3100509231 /* ADJActivityPackage.m in Sources */, + 0AB1C99E27DD4B3100509231 /* ADJActivityState.m in Sources */, + 0AB1C99F27DD4B3100509231 /* ADJAdjustFactory.m in Sources */, + 0AB1C9A027DD4B3100509231 /* ADJLogger.m in Sources */, + 0AB1C9A127DD4B3100509231 /* ADJPackageBuilder.m in Sources */, + 0AB1C9A227DD4B3100509231 /* ADJPackageParams.m in Sources */, + 0AB1C9A327DD4B3100509231 /* ADJPackageHandler.m in Sources */, + 0AB1C9A427DD4B3200509231 /* ADJRequestHandler.m in Sources */, + 0AB1C9A527DD4B3200509231 /* ADJUtil.m in Sources */, + 0AB1C9A627DD4B3200509231 /* ADJEvent.m in Sources */, + 0AB1C9A727DD4B3200509231 /* ADJAttributionHandler.m in Sources */, + 0AB1C9A827DD4B3200509231 /* ADJAttribution.m in Sources */, + 0AB1C9A927DD4B3200509231 /* ADJConfig.m in Sources */, + 0AB1C9AA27DD4B3200509231 /* ADJTimerOnce.m in Sources */, + 0AB1C9AB27DD4B3200509231 /* ADJTimerCycle.m in Sources */, + 0AB1C9AC27DD4B3200509231 /* ADJResponseData.m in Sources */, + 0AB1C9AD27DD4B3200509231 /* ADJSessionSuccess.m in Sources */, + 0AB1C9AE27DD4B3200509231 /* ADJSessionFailure.m in Sources */, + 0AB1C9AF27DD4B3200509231 /* ADJEventSuccess.m in Sources */, + 0AB1C9B027DD4B3200509231 /* ADJEventFailure.m in Sources */, + 0AB1C9B127DD4B3200509231 /* ADJBackoffStrategy.m in Sources */, + 0AB1C9B227DD4B3200509231 /* ADJSdkClickHandler.m in Sources */, + 0AB1C9B327DD4B3200509231 /* ADJSessionParameters.m in Sources */, + 0AB1C9B427DD4B3200509231 /* ADJUserDefaults.m in Sources */, + 0AB1C9B527DD4B3200509231 /* ADJSubscription.m in Sources */, + 0AB1C9B627DD4B3200509231 /* ADJUrlStrategy.m in Sources */, + 0AB1C9B727DD4B3200509231 /* ADJThirdPartySharing.m in Sources */, + 0AB1C9B827DD4B3200509231 /* ADJAdRevenue.m in Sources */, + 0AB1C9B927DD4B3200509231 /* ADJLinkResolution.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 0AB1CA2127DF462200509231 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 0AB1CA2F27DF49CB00509231 /* NSString+ADJAdditions.m in Sources */, + 0AB1CA3027DF49CB00509231 /* NSData+ADJAdditions.m in Sources */, + 0AB1CA3127DF49CB00509231 /* NSNumber+ADJAdditions.m in Sources */, + 0AB1CA3227DF49CB00509231 /* Adjust.m in Sources */, + 0AB1CA3327DF49CB00509231 /* ADJActivityHandler.m in Sources */, + 0AB1CA3427DF49CC00509231 /* ADJActivityKind.m in Sources */, + 0AB1CA3527DF49CC00509231 /* ADJActivityPackage.m in Sources */, + 0AB1CA3627DF49CC00509231 /* ADJActivityState.m in Sources */, + 0AB1CA3727DF49CC00509231 /* ADJAdjustFactory.m in Sources */, + 0AB1CA3827DF49CC00509231 /* ADJLogger.m in Sources */, + 0AB1CA3927DF49CC00509231 /* ADJPackageBuilder.m in Sources */, + 0AB1CA3A27DF49CC00509231 /* ADJPackageParams.m in Sources */, + 0AB1CA3B27DF49CC00509231 /* ADJPackageHandler.m in Sources */, + 0AB1CA3C27DF49CC00509231 /* ADJRequestHandler.m in Sources */, + 0AB1CA3D27DF49CC00509231 /* ADJUtil.m in Sources */, + 0AB1CA3E27DF49CC00509231 /* ADJEvent.m in Sources */, + 0AB1CA3F27DF49CC00509231 /* ADJAttributionHandler.m in Sources */, + 0AB1CA4027DF49CC00509231 /* ADJAttribution.m in Sources */, + 0AB1CA4127DF49CC00509231 /* ADJConfig.m in Sources */, + 0AB1CA4227DF49CC00509231 /* ADJTimerOnce.m in Sources */, + 0AB1CA4327DF49CC00509231 /* ADJTimerCycle.m in Sources */, + 0AB1CA4427DF49CC00509231 /* ADJResponseData.m in Sources */, + 0AB1CA4527DF49CC00509231 /* ADJSessionSuccess.m in Sources */, + 0AB1CA4627DF49CC00509231 /* ADJSessionFailure.m in Sources */, + 0AB1CA4727DF49CC00509231 /* ADJEventSuccess.m in Sources */, + 0AB1CA4827DF49CC00509231 /* ADJEventFailure.m in Sources */, + 0AB1CA4927DF49CC00509231 /* ADJBackoffStrategy.m in Sources */, + 0AB1CA4A27DF49CC00509231 /* ADJSdkClickHandler.m in Sources */, + 0AB1CA4B27DF49CC00509231 /* ADJSessionParameters.m in Sources */, + 0AB1CA4C27DF49CC00509231 /* ADJUserDefaults.m in Sources */, + 0AB1CA4D27DF49CC00509231 /* ADJSubscription.m in Sources */, + 0AB1CA4E27DF49CC00509231 /* ADJUrlStrategy.m in Sources */, + 0AB1CA4F27DF49CC00509231 /* ADJThirdPartySharing.m in Sources */, + 0AB1CA5027DF49CC00509231 /* ADJAdRevenue.m in Sources */, + 0AB1CA5127DF49CC00509231 /* ADJLinkResolution.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 0AB1CA6427DF5D3200509231 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 0AB1CA7227DF61F200509231 /* NSString+ADJAdditions.m in Sources */, + 0AB1CA7327DF61F200509231 /* NSData+ADJAdditions.m in Sources */, + 0AB1CA7427DF61F200509231 /* NSNumber+ADJAdditions.m in Sources */, + 0AB1CA7527DF61F200509231 /* Adjust.m in Sources */, + 0AB1CA7627DF61F200509231 /* ADJActivityHandler.m in Sources */, + 0AB1CA7727DF61F200509231 /* ADJActivityKind.m in Sources */, + 0AB1CA7827DF61F200509231 /* ADJActivityPackage.m in Sources */, + 0AB1CA7927DF61F200509231 /* ADJActivityState.m in Sources */, + 0AB1CA7A27DF61F200509231 /* ADJAdjustFactory.m in Sources */, + 0AB1CA7B27DF61F200509231 /* ADJLogger.m in Sources */, + 0AB1CA7C27DF61F200509231 /* ADJPackageBuilder.m in Sources */, + 0AB1CA7D27DF61F200509231 /* ADJPackageParams.m in Sources */, + 0AB1CA7E27DF61F200509231 /* ADJPackageHandler.m in Sources */, + 0AB1CA7F27DF61F200509231 /* ADJRequestHandler.m in Sources */, + 0AB1CA8027DF61F200509231 /* ADJUtil.m in Sources */, + 0AB1CA8127DF61F200509231 /* ADJEvent.m in Sources */, + 0AB1CA8227DF61F200509231 /* ADJAttributionHandler.m in Sources */, + 0AB1CA8327DF61F200509231 /* ADJAttribution.m in Sources */, + 0AB1CA8427DF61F200509231 /* ADJConfig.m in Sources */, + 0AB1CA8527DF61F200509231 /* ADJTimerOnce.m in Sources */, + 0AB1CA8627DF61F200509231 /* ADJTimerCycle.m in Sources */, + 0AB1CA8727DF61F200509231 /* ADJResponseData.m in Sources */, + 0AB1CA8827DF61F200509231 /* ADJSessionSuccess.m in Sources */, + 0AB1CA8927DF61F200509231 /* ADJSessionFailure.m in Sources */, + 0AB1CA8A27DF61F200509231 /* ADJEventSuccess.m in Sources */, + 0AB1CA8B27DF61F200509231 /* ADJEventFailure.m in Sources */, + 0AB1CA8C27DF61F200509231 /* ADJBackoffStrategy.m in Sources */, + 0AB1CA8D27DF61F200509231 /* ADJSdkClickHandler.m in Sources */, + 0AB1CA8E27DF61F200509231 /* ADJSessionParameters.m in Sources */, + 0AB1CA8F27DF61F200509231 /* ADJUserDefaults.m in Sources */, + 0AB1CA9027DF61F200509231 /* ADJSubscription.m in Sources */, + 0AB1CA9127DF61F200509231 /* ADJUrlStrategy.m in Sources */, + 0AB1CA9227DF61F200509231 /* ADJThirdPartySharing.m in Sources */, + 0AB1CA9327DF61F200509231 /* ADJAdRevenue.m in Sources */, + 0AB1CA9427DF61F200509231 /* ADJLinkResolution.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 0AB1CAD127DF671300509231 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 0AB1CB0927DF68C100509231 /* NSString+ADJAdditions.m in Sources */, + 0AB1CB0A27DF68C100509231 /* NSData+ADJAdditions.m in Sources */, + 0AB1CB0B27DF68C100509231 /* NSNumber+ADJAdditions.m in Sources */, + 0AB1CB0C27DF68C100509231 /* Adjust.m in Sources */, + 0AB1CB0D27DF68C100509231 /* ADJActivityHandler.m in Sources */, + 0AB1CB0E27DF68C100509231 /* ADJActivityKind.m in Sources */, + 0AB1CB0F27DF68C100509231 /* ADJActivityPackage.m in Sources */, + 0AB1CB1027DF68C100509231 /* ADJActivityState.m in Sources */, + 0AB1CB1127DF68C100509231 /* ADJAdjustFactory.m in Sources */, + 0AB1CB1227DF68C100509231 /* ADJLogger.m in Sources */, + 0AB1CB1327DF68C100509231 /* ADJPackageBuilder.m in Sources */, + 0AB1CB1427DF68C100509231 /* ADJPackageParams.m in Sources */, + 0AB1CB1527DF68C100509231 /* ADJPackageHandler.m in Sources */, + 0AB1CB1627DF68C100509231 /* ADJRequestHandler.m in Sources */, + 0AB1CB1727DF68C100509231 /* ADJUtil.m in Sources */, + 0AB1CB1827DF68C100509231 /* ADJEvent.m in Sources */, + 0AB1CB1927DF68C100509231 /* ADJAttributionHandler.m in Sources */, + 0AB1CB1A27DF68C100509231 /* ADJAttribution.m in Sources */, + 0AB1CB1B27DF68C100509231 /* ADJConfig.m in Sources */, + 0AB1CB1C27DF68C100509231 /* ADJTimerOnce.m in Sources */, + 0AB1CB1D27DF68C100509231 /* ADJTimerCycle.m in Sources */, + 0AB1CB1E27DF68C100509231 /* ADJResponseData.m in Sources */, + 0AB1CB1F27DF68C100509231 /* ADJSessionSuccess.m in Sources */, + 0AB1CB2027DF68C100509231 /* ADJSessionFailure.m in Sources */, + 0AB1CB2127DF68C100509231 /* ADJEventSuccess.m in Sources */, + 0AB1CB2227DF68C100509231 /* ADJEventFailure.m in Sources */, + 0AB1CB2327DF68C100509231 /* ADJBackoffStrategy.m in Sources */, + 0AB1CB2427DF68C100509231 /* ADJSdkClickHandler.m in Sources */, + 0AB1CB2527DF68C100509231 /* ADJSessionParameters.m in Sources */, + 0AB1CB2627DF68C100509231 /* ADJUserDefaults.m in Sources */, + 0AB1CB2727DF68C100509231 /* ADJSubscription.m in Sources */, + 0AB1CB2827DF68C100509231 /* ADJUrlStrategy.m in Sources */, + 0AB1CB2927DF68C100509231 /* ADJThirdPartySharing.m in Sources */, + 0AB1CB2A27DF68C100509231 /* ADJAdRevenue.m in Sources */, + 0AB1CB2B27DF68C100509231 /* ADJLinkResolution.m in Sources */, + 0AB1CB2C27DF68DB00509231 /* AdjustBridge.m in Sources */, + 0AB1CB2D27DF68DB00509231 /* AdjustBridgeRegister.m in Sources */, + 0AB1CB2E27DF68DB00509231 /* WebViewJavascriptBridge_JS.m in Sources */, + 0AB1CB2F27DF68DB00509231 /* WebViewJavascriptBridgeBase.m in Sources */, + 0AB1CB3027DF68DB00509231 /* WKWebViewJavascriptBridge.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; 9615158B1CD2CB2C0022D336 /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; @@ -2885,6 +3624,228 @@ /* End PBXVariantGroup section */ /* Begin XCBuildConfiguration section */ + 0AB1C97727DD450D00509231 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++17"; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_STYLE = Automatic; + DEBUG_INFORMATION_FORMAT = dwarf; + DEVELOPMENT_TEAM = QGUGW9AUMK; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + OTHER_LDFLAGS = "-ObjC"; + PRODUCT_MODULE_NAME = "$(PRODUCT_NAME:c99extidentifier)"; + PRODUCT_NAME = AdjustSdk; + PUBLIC_HEADERS_FOLDER_PATH = include/AdjustSdk; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 0AB1C97827DD450D00509231 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++17"; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_STYLE = Automatic; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEVELOPMENT_TEAM = QGUGW9AUMK; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + OTHER_LDFLAGS = "-ObjC"; + PRODUCT_MODULE_NAME = "$(PRODUCT_NAME:c99extidentifier)"; + PRODUCT_NAME = AdjustSdk; + PUBLIC_HEADERS_FOLDER_PATH = include/AdjustSdk; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + 0AB1CA2C27DF462200509231 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++17"; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_STYLE = Automatic; + DEBUG_INFORMATION_FORMAT = dwarf; + DEVELOPMENT_TEAM = QGUGW9AUMK; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + IPHONEOS_DEPLOYMENT_TARGET = 15.2; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + OTHER_LDFLAGS = "-ObjC"; + PRODUCT_MODULE_NAME = "$(PRODUCT_NAME:c99extidentifier)"; + PRODUCT_NAME = AdjustSdkTv; + PUBLIC_HEADERS_FOLDER_PATH = include/AdjustSdkTv; + SDKROOT = appletvos; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = 3; + TVOS_DEPLOYMENT_TARGET = 9.0; + }; + name = Debug; + }; + 0AB1CA2D27DF462200509231 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++17"; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_STYLE = Automatic; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEVELOPMENT_TEAM = QGUGW9AUMK; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + IPHONEOS_DEPLOYMENT_TARGET = 15.2; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + OTHER_LDFLAGS = "-ObjC"; + PRODUCT_MODULE_NAME = "$(PRODUCT_NAME:c99extidentifier)"; + PRODUCT_NAME = AdjustSdkTv; + PUBLIC_HEADERS_FOLDER_PATH = include/AdjustSdkTv; + SDKROOT = appletvos; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = 3; + TVOS_DEPLOYMENT_TARGET = 9.0; + }; + name = Release; + }; + 0AB1CA6F27DF5D3200509231 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++17"; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_STYLE = Automatic; + DEBUG_INFORMATION_FORMAT = dwarf; + DEVELOPMENT_TEAM = QGUGW9AUMK; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + "ADJUST_IM=1", + ); + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + OTHER_LDFLAGS = "-ObjC"; + PRODUCT_NAME = AdjustSdkIm; + PUBLIC_HEADERS_FOLDER_PATH = include/AdjustSdkIm; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 0AB1CA7027DF5D3200509231 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++17"; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_STYLE = Automatic; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEVELOPMENT_TEAM = QGUGW9AUMK; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_PREPROCESSOR_DEFINITIONS = "ADJUST_IM=1"; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + OTHER_LDFLAGS = "-ObjC"; + PRODUCT_NAME = AdjustSdkIm; + PUBLIC_HEADERS_FOLDER_PATH = include/AdjustSdkIm; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + 0AB1CADC27DF671300509231 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++17"; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_STYLE = Automatic; + DEBUG_INFORMATION_FORMAT = dwarf; + DEVELOPMENT_TEAM = QGUGW9AUMK; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + OTHER_LDFLAGS = "-ObjC"; + PRODUCT_NAME = AdjustSdkWebBridge; + PUBLIC_HEADERS_FOLDER_PATH = include/AdjustSdkWebBridge; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 0AB1CADD27DF671300509231 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++17"; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_STYLE = Automatic; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + DEVELOPMENT_TEAM = QGUGW9AUMK; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + OTHER_LDFLAGS = "-ObjC"; + PRODUCT_NAME = AdjustSdkWebBridge; + PUBLIC_HEADERS_FOLDER_PATH = include/AdjustSdkWebBridge; + SKIP_INSTALL = YES; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; 961515951CD2CB2C0022D336 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { @@ -3145,11 +4106,12 @@ CLANG_ENABLE_OBJC_WEAK = YES; CLANG_WARN_DOCUMENTATION_COMMENTS = YES; CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_IDENTITY = "iPhone Developer"; CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; - DEVELOPMENT_TEAM = ""; + DEVELOPMENT_TEAM = QGUGW9AUMK; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; @@ -3183,11 +4145,12 @@ CLANG_ENABLE_OBJC_WEAK = YES; CLANG_WARN_DOCUMENTATION_COMMENTS = YES; CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_IDENTITY = "iPhone Developer"; CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; - DEVELOPMENT_TEAM = ""; + DEVELOPMENT_TEAM = QGUGW9AUMK; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; @@ -3269,11 +4232,12 @@ CLANG_ENABLE_OBJC_WEAK = YES; CLANG_WARN_DOCUMENTATION_COMMENTS = YES; CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_IDENTITY = "iPhone Developer"; CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; - DEVELOPMENT_TEAM = ""; + DEVELOPMENT_TEAM = QGUGW9AUMK; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; @@ -3312,11 +4276,12 @@ CLANG_ENABLE_OBJC_WEAK = YES; CLANG_WARN_DOCUMENTATION_COMMENTS = YES; CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CODE_SIGN_IDENTITY = "iPhone Developer"; CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; - DEVELOPMENT_TEAM = ""; + DEVELOPMENT_TEAM = QGUGW9AUMK; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; @@ -3346,13 +4311,18 @@ isa = XCBuildConfiguration; buildSettings = { CLANG_WARN_UNREACHABLE_CODE = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + "CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development"; + CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; + DEVELOPMENT_TEAM = QGUGW9AUMK; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; + EXCLUDED_ARCHS = ""; GCC_NO_COMMON_BLOCKS = YES; GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; INFOPLIST_FILE = AdjustSdk/Info.plist; @@ -3367,6 +4337,8 @@ ONLY_ACTIVE_ARCH = NO; PRODUCT_BUNDLE_IDENTIFIER = com.adjust.AdjustSdk; PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; + "PROVISIONING_PROFILE_SPECIFIER[sdk=macosx*]" = ""; SKIP_INSTALL = YES; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; @@ -3378,13 +4350,18 @@ isa = XCBuildConfiguration; buildSettings = { CLANG_WARN_UNREACHABLE_CODE = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + "CODE_SIGN_IDENTITY[sdk=macosx*]" = "Apple Development"; + CODE_SIGN_STYLE = Manual; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; + DEVELOPMENT_TEAM = QGUGW9AUMK; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; + EXCLUDED_ARCHS = ""; GCC_NO_COMMON_BLOCKS = YES; GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; INFOPLIST_FILE = AdjustSdk/Info.plist; @@ -3399,6 +4376,8 @@ ONLY_ACTIVE_ARCH = NO; PRODUCT_BUNDLE_IDENTIFIER = com.adjust.AdjustSdk; PRODUCT_NAME = "$(TARGET_NAME)"; + PROVISIONING_PROFILE_SPECIFIER = ""; + "PROVISIONING_PROFILE_SPECIFIER[sdk=macosx*]" = ""; SKIP_INSTALL = YES; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; @@ -3411,10 +4390,12 @@ buildSettings = { CLANG_ANALYZER_NONNULL = YES; CLANG_WARN_UNREACHABLE_CODE = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; + DEVELOPMENT_TEAM = QGUGW9AUMK; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; @@ -3447,10 +4428,12 @@ buildSettings = { CLANG_ANALYZER_NONNULL = YES; CLANG_WARN_UNREACHABLE_CODE = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; + DEVELOPMENT_TEAM = QGUGW9AUMK; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; @@ -3481,6 +4464,42 @@ /* End XCBuildConfiguration section */ /* Begin XCConfigurationList section */ + 0AB1C98B27DD450D00509231 /* Build configuration list for PBXNativeTarget "AdjustSdkStatic" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 0AB1C97727DD450D00509231 /* Debug */, + 0AB1C97827DD450D00509231 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 0AB1CA2B27DF462200509231 /* Build configuration list for PBXNativeTarget "AdjustSdkTvStatic" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 0AB1CA2C27DF462200509231 /* Debug */, + 0AB1CA2D27DF462200509231 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 0AB1CA6E27DF5D3200509231 /* Build configuration list for PBXNativeTarget "AdjustSdkImStatic" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 0AB1CA6F27DF5D3200509231 /* Debug */, + 0AB1CA7027DF5D3200509231 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 0AB1CADB27DF671300509231 /* Build configuration list for PBXNativeTarget "AdjustSdkWebBridgeStatic" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 0AB1CADC27DF671300509231 /* Debug */, + 0AB1CADD27DF671300509231 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; 9615159E1CD2CB2C0022D336 /* Build configuration list for PBXNativeTarget "AdjustBridge" */ = { isa = XCConfigurationList; buildConfigurations = ( diff --git a/Adjust/ADJActivityHandler.m b/Adjust/ADJActivityHandler.m index 9dcd379ec..c9d3e066b 100644 --- a/Adjust/ADJActivityHandler.m +++ b/Adjust/ADJActivityHandler.m @@ -1016,6 +1016,7 @@ - (void)initI:(ADJActivityHandler *)selfI userAgent:selfI.adjustConfig.userAgent urlStrategy:sdkClickHandlerUrlStrategy]; + [selfI checkLinkMeI:selfI]; [selfI.trackingStatusManager checkForNewAttStatus]; [selfI preLaunchActionsI:selfI @@ -1770,6 +1771,7 @@ - (void)setEnabledI:(ADJActivityHandler *)selfI enabled:(BOOL)enabled { selfI.savedPreLaunch.lastMeasurementConsentTracked = nil; } + [selfI checkLinkMeI:selfI]; } if (![ADJUserDefaults getInstallTracked]) { @@ -2161,6 +2163,63 @@ - (void)setTrackingStateOptedOutI:(ADJActivityHandler *)selfI { [selfI.packageHandler flush]; } +- (void)checkLinkMeI:(ADJActivityHandler *)selfI { +#if TARGET_OS_IOS + if (@available(iOS 15.0, *)) { + if (selfI.adjustConfig.linkMeEnabled == NO) { + [self.logger debug:@"LinkMe not allowed by client"]; + return; + } + if ([ADJUserDefaults getLinkMeChecked] == YES) { + [self.logger debug:@"LinkMe already checked"]; + return; + } + if (selfI.internalState.isFirstLaunch == NO) { + [self.logger debug:@"LinkMe only valid for install"]; + return; + } + if ([ADJUserDefaults getGdprForgetMe]) { + [self.logger debug:@"LinkMe not happening for GDPR forgotten user"]; + return; + } + + UIPasteboard *pasteboard = [UIPasteboard generalPasteboard]; + if ([pasteboard hasURLs] == NO) { + [self.logger debug:@"LinkMe general board not found"]; + return; + } + + NSURL *pasteboardUrl = [pasteboard URL]; + if (pasteboardUrl == nil) { + [self.logger debug:@"LinkMe content not found"]; + return; + } + + NSString *pasteboardUrlString = [pasteboardUrl absoluteString]; + if (pasteboardUrlString == nil) { + [self.logger debug:@"LinkMe content could not be converted to string"]; + return; + } + + // send sdk_click + double now = [NSDate.date timeIntervalSince1970]; + ADJPackageBuilder *clickBuilder = [[ADJPackageBuilder alloc] initWithPackageParams:selfI.packageParams + activityState:selfI.activityState + config:selfI.adjustConfig + sessionParameters:selfI.sessionParameters + trackingStatusManager:self.trackingStatusManager + createdAt:now]; + clickBuilder.clickTime = [NSDate dateWithTimeIntervalSince1970:now]; + ADJActivityPackage *clickPackage = [clickBuilder buildClickPackage:@"linkme" linkMeUrl:pasteboardUrlString]; + [selfI.sdkClickHandler sendSdkClick:clickPackage]; + + [ADJUserDefaults setLinkMeChecked]; + } else { + [self.logger warn:@"LinkMe feature is supported on iOS 15.0 and above"]; + } +#endif +} + #pragma mark - private - (BOOL)isEnabledI:(ADJActivityHandler *)selfI { diff --git a/Adjust/ADJConfig.h b/Adjust/ADJConfig.h index c80e12510..7a04903db 100644 --- a/Adjust/ADJConfig.h +++ b/Adjust/ADJConfig.h @@ -214,6 +214,11 @@ */ @property (nonatomic, copy, readwrite, nullable) NSString *urlStrategy; +/** + * @brief Enables/disables linkMe + */ +@property (nonatomic, assign) BOOL linkMeEnabled; + /** * @brief Get configuration object for the initialization of the Adjust SDK. * diff --git a/Adjust/ADJConfig.m b/Adjust/ADJConfig.m index 8a16eab5c..60389bcf8 100644 --- a/Adjust/ADJConfig.m +++ b/Adjust/ADJConfig.m @@ -71,6 +71,7 @@ - (id)initWithAppToken:(NSString *)appToken self.allowIdfaReading = YES; self.allowiAdInfoReading = YES; self.allowAdServicesInfoReading = YES; + self.linkMeEnabled = NO; _isSKAdNetworkHandlingActive = YES; return self; @@ -213,6 +214,7 @@ - (id)copyWithZone:(NSZone *)zone { copy->_appSecret = [self.appSecret copyWithZone:zone]; copy->_isSKAdNetworkHandlingActive = self.isSKAdNetworkHandlingActive; copy->_urlStrategy = [self.urlStrategy copyWithZone:zone]; + copy.linkMeEnabled = self.linkMeEnabled; // adjust delegate not copied } diff --git a/Adjust/ADJPackageBuilder.h b/Adjust/ADJPackageBuilder.h index d69d876ff..2390d7168 100644 --- a/Adjust/ADJPackageBuilder.h +++ b/Adjust/ADJPackageBuilder.h @@ -20,6 +20,8 @@ @property (nonatomic, copy) NSString * _Nullable deeplink; +@property (nonatomic, copy) NSString * _Nullable reftag; + @property (nonatomic, copy) NSDate * _Nullable clickTime; @property (nonatomic, copy) NSDate * _Nullable purchaseTime; @@ -53,6 +55,9 @@ token:(NSString * _Nullable)token errorCodeNumber:(NSNumber * _Nullable)errorCodeNumber; +- (ADJActivityPackage * _Nullable)buildClickPackage:(NSString * _Nullable)clickSource + linkMeUrl:(NSString * _Nullable)linkMeUrl; + - (ADJActivityPackage * _Nullable)buildAttributionPackage:(NSString * _Nullable)initiatedBy; - (ADJActivityPackage * _Nullable)buildGdprPackage; diff --git a/Adjust/ADJPackageBuilder.m b/Adjust/ADJPackageBuilder.m index 18d200255..8da39c712 100644 --- a/Adjust/ADJPackageBuilder.m +++ b/Adjust/ADJPackageBuilder.m @@ -159,6 +159,20 @@ - (ADJActivityPackage *)buildClickPackage:(NSString *)clickSource return [self buildClickPackage:clickSource extraParameters:parameters]; } +- (ADJActivityPackage *)buildClickPackage:(NSString *)clickSource + linkMeUrl:(NSString * _Nullable)linkMeUrl { + + NSMutableDictionary *parameters = [NSMutableDictionary dictionary]; + + if (linkMeUrl != nil) { + [ADJPackageBuilder parameters:parameters + setString:linkMeUrl + forKey:@"content"]; + } + + return [self buildClickPackage:clickSource extraParameters:parameters]; +} + - (ADJActivityPackage *)buildClickPackage:(NSString *)clickSource extraParameters:(NSDictionary *)extraParameters { NSMutableDictionary *parameters = [self getClickParameters:clickSource]; if (extraParameters != nil) { @@ -451,6 +465,10 @@ - (NSMutableDictionary *)getEventParameters:(BOOL)isInDelay forEventPackage:(ADJ [ADJPackageBuilder parameters:parameters setDate:[ADJUserDefaults getSkadRegisterCallTimestamp] forKey:@"skadn_registered_at"]; [ADJPackageBuilder parameters:parameters setDate1970:(double)self.packageParams.startedAt forKey:@"started_at"]; + if (event.transactionId) { + [ADJPackageBuilder parameters:parameters setString:event.transactionId forKey:@"deduplication_id"]; + } + if ([self.trackingStatusManager canGetAttStatus]) { [ADJPackageBuilder parameters:parameters setInt:self.trackingStatusManager.attStatus forKey:@"att_status"]; @@ -520,6 +538,7 @@ - (NSMutableDictionary *)getInfoParameters:(NSString *)source { [ADJPackageBuilder parameters:parameters setDate:self.clickTime forKey:@"click_time"]; [ADJPackageBuilder parameters:parameters setDate1970:self.createdAt forKey:@"created_at"]; [ADJPackageBuilder parameters:parameters setString:self.deeplink forKey:@"deeplink"]; + [ADJPackageBuilder parameters:parameters setString:self.reftag forKey:@"reftag"]; [ADJPackageBuilder parameters:parameters setString:self.adjustConfig.defaultTracker forKey:@"default_tracker"]; [ADJPackageBuilder parameters:parameters setDictionary:self.attributionDetails forKey:@"details"]; [ADJPackageBuilder parameters:parameters setString:self.packageParams.deviceName forKey:@"device_name"]; @@ -737,6 +756,7 @@ - (NSMutableDictionary *)getClickParameters:(NSString *)source { [ADJPackageBuilder parameters:parameters setDate:self.clickTime forKey:@"click_time"]; [ADJPackageBuilder parameters:parameters setDate1970:self.createdAt forKey:@"created_at"]; [ADJPackageBuilder parameters:parameters setString:self.deeplink forKey:@"deeplink"]; + [ADJPackageBuilder parameters:parameters setString:self.reftag forKey:@"reftag"]; [ADJPackageBuilder parameters:parameters setString:self.adjustConfig.defaultTracker forKey:@"default_tracker"]; [ADJPackageBuilder parameters:parameters setDictionary:self.attributionDetails forKey:@"details"]; [ADJPackageBuilder parameters:parameters setString:self.packageParams.deviceName forKey:@"device_name"]; @@ -917,6 +937,7 @@ - (NSMutableDictionary *)getDisableThirdPartySharingParameters { [ADJPackageBuilder parameters:parameters setDate:self.clickTime forKey:@"click_time"]; [ADJPackageBuilder parameters:parameters setDate1970:self.createdAt forKey:@"created_at"]; [ADJPackageBuilder parameters:parameters setString:self.deeplink forKey:@"deeplink"]; + [ADJPackageBuilder parameters:parameters setString:self.reftag forKey:@"reftag"]; [ADJPackageBuilder parameters:parameters setString:self.adjustConfig.defaultTracker forKey:@"default_tracker"]; [ADJPackageBuilder parameters:parameters setDictionary:self.attributionDetails forKey:@"details"]; [ADJPackageBuilder parameters:parameters setString:self.packageParams.deviceName forKey:@"device_name"]; @@ -984,6 +1005,7 @@ - (NSMutableDictionary *)getThirdPartySharingParameters:(nonnull ADJThirdPartySh [ADJPackageBuilder parameters:parameters setDate:self.clickTime forKey:@"click_time"]; [ADJPackageBuilder parameters:parameters setDate1970:self.createdAt forKey:@"created_at"]; [ADJPackageBuilder parameters:parameters setString:self.deeplink forKey:@"deeplink"]; + [ADJPackageBuilder parameters:parameters setString:self.reftag forKey:@"reftag"]; [ADJPackageBuilder parameters:parameters setString:self.adjustConfig.defaultTracker forKey:@"default_tracker"]; [ADJPackageBuilder parameters:parameters setDictionary:self.attributionDetails forKey:@"details"]; [ADJPackageBuilder parameters:parameters setString:self.packageParams.deviceName forKey:@"device_name"]; @@ -1057,6 +1079,7 @@ - (NSMutableDictionary *)getMeasurementConsentParameters:(BOOL)enabled { [ADJPackageBuilder parameters:parameters setDate:self.clickTime forKey:@"click_time"]; [ADJPackageBuilder parameters:parameters setDate1970:self.createdAt forKey:@"created_at"]; [ADJPackageBuilder parameters:parameters setString:self.deeplink forKey:@"deeplink"]; + [ADJPackageBuilder parameters:parameters setString:self.reftag forKey:@"reftag"]; [ADJPackageBuilder parameters:parameters setString:self.adjustConfig.defaultTracker forKey:@"default_tracker"]; [ADJPackageBuilder parameters:parameters setDictionary:self.attributionDetails forKey:@"details"]; [ADJPackageBuilder parameters:parameters setString:self.packageParams.deviceName forKey:@"device_name"]; diff --git a/Adjust/ADJUserDefaults.h b/Adjust/ADJUserDefaults.h index 1664de1d1..0c854d4d2 100644 --- a/Adjust/ADJUserDefaults.h +++ b/Adjust/ADJUserDefaults.h @@ -61,4 +61,8 @@ + (NSDate *)getSkadRegisterCallTimestamp; ++ (void)setLinkMeChecked; + ++ (BOOL)getLinkMeChecked; + @end diff --git a/Adjust/ADJUserDefaults.m b/Adjust/ADJUserDefaults.m index ecdd56d08..bc61b8f30 100644 --- a/Adjust/ADJUserDefaults.m +++ b/Adjust/ADJUserDefaults.m @@ -18,6 +18,7 @@ static NSString * const PREFS_KEY_IAD_ERRORS = @"adj_iad_errors"; static NSString * const PREFS_KEY_ADSERVICES_TRACKED = @"adj_adservices_tracked"; static NSString * const PREFS_KEY_SKAD_REGISTER_CALL_TIME = @"adj_skad_register_call_time"; +static NSString * const PREFS_KEY_LINK_ME_CHECKED = @"adj_link_me_checked"; @implementation ADJUserDefaults @@ -138,6 +139,14 @@ + (NSDate *)getSkadRegisterCallTimestamp { return [[NSUserDefaults standardUserDefaults] objectForKey:PREFS_KEY_SKAD_REGISTER_CALL_TIME]; } ++ (void)setLinkMeChecked { + [[NSUserDefaults standardUserDefaults] setBool:YES forKey:PREFS_KEY_LINK_ME_CHECKED]; +} + ++ (BOOL)getLinkMeChecked { + return [[NSUserDefaults standardUserDefaults] boolForKey:PREFS_KEY_LINK_ME_CHECKED]; +} + + (void)clearAdjustStuff { [[NSUserDefaults standardUserDefaults] removeObjectForKey:PREFS_KEY_PUSH_TOKEN_DATA]; [[NSUserDefaults standardUserDefaults] removeObjectForKey:PREFS_KEY_PUSH_TOKEN_STRING]; @@ -149,6 +158,7 @@ + (void)clearAdjustStuff { [[NSUserDefaults standardUserDefaults] removeObjectForKey:PREFS_KEY_IAD_ERRORS]; [[NSUserDefaults standardUserDefaults] removeObjectForKey:PREFS_KEY_ADSERVICES_TRACKED]; [[NSUserDefaults standardUserDefaults] removeObjectForKey:PREFS_KEY_SKAD_REGISTER_CALL_TIME]; + [[NSUserDefaults standardUserDefaults] removeObjectForKey:PREFS_KEY_LINK_ME_CHECKED]; } @end diff --git a/Adjust/ADJUtil.m b/Adjust/ADJUtil.m index 57dc2a1e5..97ccf93b8 100644 --- a/Adjust/ADJUtil.m +++ b/Adjust/ADJUtil.m @@ -39,7 +39,7 @@ static NSRegularExpression *shortUniversalLinkRegex = nil; static NSRegularExpression *excludedDeeplinkRegex = nil; -static NSString * const kClientSdk = @"ios4.30.0"; +static NSString * const kClientSdk = @"ios4.31.0"; static NSString * const kDeeplinkParam = @"deep_link="; static NSString * const kSchemeDelimiter = @"://"; static NSString * const kDefaultScheme = @"AdjustUniversalScheme"; diff --git a/Adjust/Adjust.h b/Adjust/Adjust.h index 54e3c12cf..6d4b932cc 100644 --- a/Adjust/Adjust.h +++ b/Adjust/Adjust.h @@ -2,7 +2,7 @@ // Adjust.h // Adjust SDK // -// V4.30.0 +// V4.31.0 // Created by Christian Wellenbrock (@wellle) on 23rd July 2013. // Copyright (c) 2012-2021 Adjust GmbH. All rights reserved. // diff --git a/AdjustBridge/AdjustBridge.m b/AdjustBridge/AdjustBridge.m index 133acd4e9..f9c209efc 100644 --- a/AdjustBridge/AdjustBridge.m +++ b/AdjustBridge/AdjustBridge.m @@ -188,6 +188,7 @@ - (void)loadWKWebViewBridge:(WKWebView *)wkWebView NSString *logLevel = [data objectForKey:@"logLevel"]; NSNumber *eventBufferingEnabled = [data objectForKey:@"eventBufferingEnabled"]; NSNumber *coppaCompliantEnabled = [data objectForKey:@"coppaCompliantEnabled"]; + NSNumber *linkMeEnabled = [data objectForKey:@"linkMeEnabled"]; NSNumber *sendInBackground = [data objectForKey:@"sendInBackground"]; NSNumber *delayStart = [data objectForKey:@"delayStart"]; NSString *userAgent = [data objectForKey:@"userAgent"]; @@ -243,6 +244,9 @@ - (void)loadWKWebViewBridge:(WKWebView *)wkWebView if ([self isFieldValid:coppaCompliantEnabled]) { [adjustConfig setCoppaCompliantEnabled:[coppaCompliantEnabled boolValue]]; } + if ([self isFieldValid:linkMeEnabled]) { + [adjustConfig setLinkMeEnabled:[linkMeEnabled boolValue]]; + } if ([self isFieldValid:sendInBackground]) { [adjustConfig setSendInBackground:[sendInBackground boolValue]]; } diff --git a/AdjustBridge/AdjustBridgeRegister.m b/AdjustBridge/AdjustBridgeRegister.m index 3ed697b11..33da595c3 100644 --- a/AdjustBridge/AdjustBridgeRegister.m +++ b/AdjustBridge/AdjustBridgeRegister.m @@ -246,7 +246,7 @@ + (NSString *)adjust_js { if (this.sdkPrefix) { return this.sdkPrefix; } else { - return 'web-bridge4.30.0'; + return 'web-bridge4.31.0'; } }, setTestOptions: function(testOptions) { @@ -324,6 +324,7 @@ + (NSString *)adjust_js { this.logLevel = null; this.eventBufferingEnabled = null; this.coppaCompliantEnabled = null; + this.linkMeEnabled = null; this.sendInBackground = null; this.delayStart = null; this.userAgent = null; @@ -405,6 +406,9 @@ + (NSString *)adjust_js { AdjustConfig.prototype.setCoppaCompliantEnabled = function(isEnabled) { this.coppaCompliantEnabled = isEnabled; }; + AdjustConfig.prototype.setLinkMeEnabled = function(isEnabled) { + this.linkMeEnabled = isEnabled; + }; AdjustConfig.prototype.setSendInBackground = function(isEnabled) { this.sendInBackground = isEnabled; }; diff --git a/AdjustSdkImStatic/AdjustSdkIm.h b/AdjustSdkImStatic/AdjustSdkIm.h new file mode 100644 index 000000000..17130f4ab --- /dev/null +++ b/AdjustSdkImStatic/AdjustSdkIm.h @@ -0,0 +1,23 @@ +// +// AdjustSdkImStatic.h +// AdjustSdkImStatic +// +// Created by Genady Buchatsky on 14.03.22. +// Copyright © 2022 Adjust GmbH. All rights reserved. +// + +#import + +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import diff --git a/AdjustSdkImStatic/module.modulemap b/AdjustSdkImStatic/module.modulemap new file mode 100644 index 000000000..2d8818ed7 --- /dev/null +++ b/AdjustSdkImStatic/module.modulemap @@ -0,0 +1,6 @@ +framework module AdjustSdkIm { + umbrella header "AdjustSdkIm.h" + + export * + module * { export * } +} diff --git a/AdjustSdkStatic/AdjustSdk.h b/AdjustSdkStatic/AdjustSdk.h new file mode 100644 index 000000000..c046f2c77 --- /dev/null +++ b/AdjustSdkStatic/AdjustSdk.h @@ -0,0 +1,23 @@ +// +// AdjustSdkStatic.h +// AdjustSdkStatic +// +// Created by Genady Buchatsky on 12.03.22. +// Copyright © 2022 Adjust GmbH. All rights reserved. +// + +#import + +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import diff --git a/AdjustSdkStatic/module.modulemap b/AdjustSdkStatic/module.modulemap new file mode 100644 index 000000000..a2b631561 --- /dev/null +++ b/AdjustSdkStatic/module.modulemap @@ -0,0 +1,6 @@ +framework module AdjustSdk { + umbrella header "AdjustSdk.h" + + export * + module * { export * } +} diff --git a/AdjustSdkTvStatic/AdjustSdkTv.h b/AdjustSdkTvStatic/AdjustSdkTv.h new file mode 100644 index 000000000..6ce5fbb6b --- /dev/null +++ b/AdjustSdkTvStatic/AdjustSdkTv.h @@ -0,0 +1,23 @@ +// +// AdjustSdkTvStatic.h +// AdjustSdkTvStatic +// +// Created by Genady Buchatsky on 14.03.22. +// Copyright © 2022 Adjust GmbH. All rights reserved. +// + +#import + +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import diff --git a/AdjustSdkTvStatic/module.modulemap b/AdjustSdkTvStatic/module.modulemap new file mode 100644 index 000000000..a85ddab7c --- /dev/null +++ b/AdjustSdkTvStatic/module.modulemap @@ -0,0 +1,6 @@ +framework module AdjustSdkTv { + umbrella header "AdjustSdkTv.h" + + export * + module * { export * } +} diff --git a/AdjustSdkWebBridgeStatic/AdjustSdkWebBridge.h b/AdjustSdkWebBridgeStatic/AdjustSdkWebBridge.h new file mode 100644 index 000000000..fb37cda2a --- /dev/null +++ b/AdjustSdkWebBridgeStatic/AdjustSdkWebBridge.h @@ -0,0 +1,30 @@ +// +// AdjustSdkWebBridgeStatic.h +// AdjustSdkWebBridgeStatic +// +// Created by Genady Buchatsky on 14.03.22. +// Copyright © 2022 Adjust GmbH. All rights reserved. +// + +#import + +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import +#import + +// Exposing entire WebViewJavascriptBridge framework +#import +#import +#import diff --git a/AdjustSdkWebBridgeStatic/module.modulemap b/AdjustSdkWebBridgeStatic/module.modulemap new file mode 100644 index 000000000..b82e403e6 --- /dev/null +++ b/AdjustSdkWebBridgeStatic/module.modulemap @@ -0,0 +1,6 @@ +framework module AdjustSdkWebBridge { + umbrella header "AdjustSdkWebBridge.h" + + export * + module * { export * } +} diff --git a/AdjustTests/AdjustTestApp/AdjustTestApp/ATAAdjustCommandExecutor.m b/AdjustTests/AdjustTestApp/AdjustTestApp/ATAAdjustCommandExecutor.m index 0b7781de3..258fd2950 100644 --- a/AdjustTests/AdjustTestApp/AdjustTestApp/ATAAdjustCommandExecutor.m +++ b/AdjustTests/AdjustTestApp/AdjustTestApp/ATAAdjustCommandExecutor.m @@ -227,6 +227,13 @@ - (void)config:(NSDictionary *)parameters { adjustConfig = [ADJConfig configWithAppToken:appToken environment:environment]; [self.savedConfigs setObject:adjustConfig forKey:configNumber]; } + + UIPasteboard *pasteboard = [UIPasteboard generalPasteboard]; + pasteboard.URL = nil; + NSString *pasteboardContent = [parameters objectForKey:@"pasteboard"][0]; + if (pasteboardContent != nil) { + pasteboard.URL = [NSURL URLWithString:pasteboardContent]; + } if ([parameters objectForKey:@"logLevel"]) { NSString *logLevelS = [parameters objectForKey:@"logLevel"][0]; @@ -340,6 +347,11 @@ - (void)config:(NSDictionary *)parameters { NSString *externalDeviceId = [parameters objectForKey:@"externalDeviceId"][0]; [adjustConfig setExternalDeviceId:externalDeviceId]; } + + if ([parameters objectForKey:@"checkPasteboard"]) { + NSString *checkPasteboardS = [parameters objectForKey:@"checkPasteboard"][0]; + [adjustConfig setLinkMeEnabled:[checkPasteboardS boolValue]]; + } if ([parameters objectForKey:@"attributionCallbackSendAll"]) { NSLog(@"attributionCallbackSendAll detected"); diff --git a/AdjustTests/AdjustTestLibrary/AdjustTestLibrary.xcodeproj/project.pbxproj b/AdjustTests/AdjustTestLibrary/AdjustTestLibrary.xcodeproj/project.pbxproj index 4732e8707..08cc058d1 100644 --- a/AdjustTests/AdjustTestLibrary/AdjustTestLibrary.xcodeproj/project.pbxproj +++ b/AdjustTests/AdjustTestLibrary/AdjustTestLibrary.xcodeproj/project.pbxproj @@ -296,7 +296,7 @@ ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "set -e\n\n# If we're already inside this script then die\nif [ -n \"$RW_MULTIPLATFORM_BUILD_IN_PROGRESS\" ]; then\nexit 0\nfi\nexport RW_MULTIPLATFORM_BUILD_IN_PROGRESS=1\n\nRW_FRAMEWORK_NAME=${PROJECT_NAME}\nRW_INPUT_STATIC_LIB=\"lib${PROJECT_NAME}.a\"\nRW_FRAMEWORK_LOCATION=\"${BUILT_PRODUCTS_DIR}/static/${RW_FRAMEWORK_NAME}.framework\"\n\nfunction build_static_library {\n echo \"1\"\n echo \"${BUILD_DIR}\"\n # Will rebuild the static library as specified\n # build_static_library sdk\n xcrun xcodebuild -project \"${PROJECT_FILE_PATH}\" \\\n -target \"${TARGET_NAME}\" \\\n -configuration \"${CONFIGURATION}\" \\\n -sdk \"${1}\" \\\n ONLY_ACTIVE_ARCH=NO \\\n BUILD_DIR=\"${BUILD_DIR}\" \\\n OBJROOT=\"${OBJROOT}/DependantBuilds\" \\\n BUILD_ROOT=\"${BUILD_ROOT}\" \\\n SYMROOT=\"${SYMROOT}\" $ACTION\n}\n\nfunction make_fat_library {\n # Will smash 2 static libs together\n # make_fat_library in1 in2 out\n xcrun lipo -create \"${1}\" \"${2}\" -output \"${3}\"\n}\n\n# 1 - Extract the platform (iphoneos/iphonesimulator) from the SDK name\nif [[ \"$SDK_NAME\" =~ ([A-Za-z]+) ]]; then\nRW_SDK_PLATFORM=${BASH_REMATCH[1]}\nelse\necho \"Could not find platform name from SDK_NAME: $SDK_NAME\"\nexit 1\nfi\n\n# 2 - Extract the version from the SDK\nif [[ \"$SDK_NAME\" =~ ([0-9]+.*$) ]]; then\nRW_SDK_VERSION=${BASH_REMATCH[1]}\nelse\necho \"Could not find sdk version from SDK_NAME: $SDK_NAME\"\nexit 1\nfi\n\n# 3 - Determine the other platform\nif [ \"$RW_SDK_PLATFORM\" == \"iphoneos\" ]; then\nRW_OTHER_PLATFORM=iphonesimulator\nelse\nRW_OTHER_PLATFORM=iphoneos\nfi\n\n# 4 - Find the build directory\nif [[ \"$BUILT_PRODUCTS_DIR\" =~ (.*)$RW_SDK_PLATFORM$ ]]; then\nRW_OTHER_BUILT_PRODUCTS_DIR=\"${BASH_REMATCH[1]}${RW_OTHER_PLATFORM}\"\nelse\necho \"Could not find other platform build directory.\"\nexit 1\nfi\n\n# Build the other platform.\nbuild_static_library \"${RW_OTHER_PLATFORM}${RW_SDK_VERSION}\"\n\n# If we're currently building for iphonesimulator, then need to rebuild\n# to ensure that we get both i386 and x86_64\nif [ \"$RW_SDK_PLATFORM\" == \"iphonesimulator\" ]; then\nbuild_static_library \"${SDK_NAME}\"\nfi\n\n# Join the 2 static libs into 1 and push into the .framework\nmake_fat_library \"${BUILT_PRODUCTS_DIR}/${RW_INPUT_STATIC_LIB}\" \\\n\"${RW_OTHER_BUILT_PRODUCTS_DIR}/${RW_INPUT_STATIC_LIB}\" \\\n\"${RW_FRAMEWORK_LOCATION}/Versions/A/${RW_FRAMEWORK_NAME}\"\n\n# Ensure that the framework is present in both platform's build directories\ncp -a \"${RW_FRAMEWORK_LOCATION}/Versions/A/${RW_FRAMEWORK_NAME}\" \\\n\"${RW_OTHER_BUILT_PRODUCTS_DIR}/static/${RW_FRAMEWORK_NAME}.framework/Versions/A/${RW_FRAMEWORK_NAME}\"\n\n# Copy the framework to the project directory\nditto \"${RW_FRAMEWORK_LOCATION}\" \"${SRCROOT}/../../frameworks/static/${RW_FRAMEWORK_NAME}.framework\"\n"; + shellScript = "set -e\n\n# If we're already inside this script then die\nif [ -n \"$RW_MULTIPLATFORM_BUILD_IN_PROGRESS\" ]; then\nexit 0\nfi\nexport RW_MULTIPLATFORM_BUILD_IN_PROGRESS=1\n\nRW_FRAMEWORK_NAME=${PROJECT_NAME}\nRW_INPUT_STATIC_LIB=\"lib${PROJECT_NAME}.a\"\nRW_FRAMEWORK_LOCATION=\"${BUILT_PRODUCTS_DIR}/static/${RW_FRAMEWORK_NAME}.framework\"\n\nfunction build_static_library {\n echo \"1\"\n echo \"${BUILD_DIR}\"\n # Will rebuild the static library as specified\n # build_static_library sdk\n xcrun xcodebuild -project \"${PROJECT_FILE_PATH}\" \\\n -target \"${TARGET_NAME}\" \\\n -configuration \"${CONFIGURATION}\" \\\n -sdk \"${1}\" \\\n ONLY_ACTIVE_ARCH=NO \\\n BUILD_DIR=\"${BUILD_DIR}\" \\\n OBJROOT=\"${OBJROOT}/DependantBuilds\" \\\n BUILD_ROOT=\"${BUILD_ROOT}\" \\\n SYMROOT=\"${SYMROOT}\" $ACTION\n}\n\nfunction make_fat_library {\n # Will smash 2 static libs together\n # make_fat_library in1 in2 out\n xcrun lipo -create \"${1}\" \"${2}\" -output \"${3}\"\n}\n\n# 1 - Extract the platform (iphoneos/iphonesimulator) from the SDK name\nif [[ \"$SDK_NAME\" =~ ([A-Za-z]+) ]]; then\nRW_SDK_PLATFORM=${BASH_REMATCH[1]}\nelse\necho \"Could not find platform name from SDK_NAME: $SDK_NAME\"\nexit 1\nfi\n\n# 2 - Extract the version from the SDK\nif [[ \"$SDK_NAME\" =~ ([0-9]+.*$) ]]; then\nRW_SDK_VERSION=${BASH_REMATCH[1]}\nelse\necho \"Could not find sdk version from SDK_NAME: $SDK_NAME\"\nexit 1\nfi\n\n# 3 - Determine the other platform\nif [ \"$RW_SDK_PLATFORM\" == \"iphoneos\" ]; then\nRW_OTHER_PLATFORM=iphonesimulator\nelse\nRW_OTHER_PLATFORM=iphoneos\nfi\n\n# 4 - Find the build directory\nif [[ \"$BUILT_PRODUCTS_DIR\" =~ (.*)$RW_SDK_PLATFORM$ ]]; then\nRW_OTHER_BUILT_PRODUCTS_DIR=\"${BASH_REMATCH[1]}${RW_OTHER_PLATFORM}\"\nelse\necho \"Could not find other platform build directory.\"\nexit 1\nfi\n\n# Build the other platform.\nbuild_static_library \"${RW_OTHER_PLATFORM}${RW_SDK_VERSION}\"\n\n# If we're currently building for iphonesimulator, then need to rebuild\n# to ensure that we get both i386 and x86_64\nif [ \"$RW_SDK_PLATFORM\" == \"iphonesimulator\" ]; then\nbuild_static_library \"${SDK_NAME}\"\nfi\n\n# Join the 2 static libs into 1 and push into the .framework\nmake_fat_library \"${BUILT_PRODUCTS_DIR}/${RW_INPUT_STATIC_LIB}\" \\\n\"${RW_OTHER_BUILT_PRODUCTS_DIR}/${RW_INPUT_STATIC_LIB}\" \\\n\"${RW_FRAMEWORK_LOCATION}/Versions/A/${RW_FRAMEWORK_NAME}\"\n\n# Ensure that the framework is present in both platform's build directories\ncp -a \"${RW_FRAMEWORK_LOCATION}/Versions/A/${RW_FRAMEWORK_NAME}\" \\\n\"${RW_OTHER_BUILT_PRODUCTS_DIR}/static/${RW_FRAMEWORK_NAME}.framework/Versions/A/${RW_FRAMEWORK_NAME}\"\n\n# Copy the framework to the project directory\nditto \"${RW_FRAMEWORK_LOCATION}\" \"${SRCROOT}/../../sdk_distribution/test-static-framework/${RW_FRAMEWORK_NAME}.framework\"\n"; }; 9D8AB2B6203F202B0015DA32 /* Build Framework */ = { isa = PBXShellScriptBuildPhase; @@ -310,7 +310,7 @@ ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; - shellScript = "set -e\n\nexport FRAMEWORK_LOCN=\"${BUILT_PRODUCTS_DIR}/Static/${PRODUCT_NAME}.framework\"\n\n# Create the path to the real Headers die\nmkdir -p \"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n\n# Create the required symlinks\n/bin/ln -sfh A \"${FRAMEWORK_LOCN}/Versions/Current\"\n/bin/ln -sfh Versions/Current/Headers \"${FRAMEWORK_LOCN}/Headers\"\n/bin/ln -sfh \"Versions/Current/${PRODUCT_NAME}\" \\\n\"${FRAMEWORK_LOCN}/${PRODUCT_NAME}\"\n\n# Copy the public headers into the framework\n/bin/cp -a \"${TARGET_BUILD_DIR}/${PUBLIC_HEADERS_FOLDER_PATH}/\" \\\n\"${FRAMEWORK_LOCN}/Versions/A/Headers\""; + shellScript = "set -e\n\nexport FRAMEWORK_LOCN=\"${BUILT_PRODUCTS_DIR}/Static/${PRODUCT_NAME}.framework\"\n\n# Create the path to the real Headers die\nmkdir -p \"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n\n# Create the required symlinks\n/bin/ln -sfh A \"${FRAMEWORK_LOCN}/Versions/Current\"\n/bin/ln -sfh Versions/Current/Headers \"${FRAMEWORK_LOCN}/Headers\"\n/bin/ln -sfh \"Versions/Current/${PRODUCT_NAME}\" \\\n\"${FRAMEWORK_LOCN}/${PRODUCT_NAME}\"\n\n# Copy the public headers into the framework\n/bin/cp -a \"${TARGET_BUILD_DIR}/${PUBLIC_HEADERS_FOLDER_PATH}/\" \\\n\"${FRAMEWORK_LOCN}/Versions/A/Headers\"\n"; }; /* End PBXShellScriptBuildPhase section */ diff --git a/AdjustTests/AdjustUnitTests/ADJPackageFields.m b/AdjustTests/AdjustUnitTests/ADJPackageFields.m index defc6ca98..c10a8ba2e 100644 --- a/AdjustTests/AdjustUnitTests/ADJPackageFields.m +++ b/AdjustTests/AdjustUnitTests/ADJPackageFields.m @@ -16,7 +16,7 @@ - (id) init { // default values self.appToken = @"qwerty123456"; - self.clientSdk = @"ios4.30.0"; + self.clientSdk = @"ios4.31.0"; self.suffix = @""; self.environment = @"sandbox"; diff --git a/CHANGELOG.md b/CHANGELOG.md index be9a70298..c5aaec0d1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +### Version 4.31.0 (18th July 2022) +#### Added +- Added support for `LinkMe` feature. +- Added ability to build SDKs as `xcframework`s. + +--- + ### Version 4.30.0 (3rd May 2022) #### Added - Added ability to mark your app as COPPA compliant. You can enable this setting by calling `setCoppaCompliantEnabled` method of `AdjustConfig` instance with boolean parameter `true`. diff --git a/README.md b/README.md index 67f73dc75..9bd0548fa 100644 --- a/README.md +++ b/README.md @@ -96,13 +96,13 @@ We will describe the steps to integrate the Adjust SDK into your iOS project. We If you're using [CocoaPods][cocoapods], you can add the following line to your `Podfile` and continue from [this step](#sdk-integrate): ```ruby -pod 'Adjust', '~> 4.30.0' +pod 'Adjust', '~> 4.31.0' ``` or: ```ruby -pod 'Adjust', :git => 'https://github.com/adjust/ios_sdk.git', :tag => 'v4.30.0' +pod 'Adjust', :git => 'https://github.com/adjust/ios_sdk.git', :tag => 'v4.31.0' ``` --- diff --git a/VERSION b/VERSION index 598ce0d49..984f695d6 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -4.30.0 +4.31.0 diff --git a/doc/chinese/README.md b/doc/chinese/README.md index 93e1201bc..7ba933771 100644 --- a/doc/chinese/README.md +++ b/doc/chinese/README.md @@ -95,13 +95,13 @@ 如果您正在使用 [CocoaPods][cocoapods],可以将以下代码行添加至 `Podfile`,然后继续进行[此步骤](#sdk-integrate): ```ruby -pod 'Adjust', '~> 4.30.0' +pod 'Adjust', '~> 4.31.0' ``` 或: ```ruby -pod 'Adjust', :git => 'https://github.com/adjust/ios_sdk.git', :tag => 'v4.30.0' +pod 'Adjust', :git => 'https://github.com/adjust/ios_sdk.git', :tag => 'v4.31.0' ``` --- diff --git a/doc/english/migrate.md b/doc/english/migrate.md index 7e7a867ad..13858778d 100644 --- a/doc/english/migrate.md +++ b/doc/english/migrate.md @@ -1,4 +1,4 @@ -## Migrate your Adjust SDK for iOS to v4.30.0 from v3.4.0 +## Migrate your Adjust SDK for iOS to v4.31.0 from v3.4.0 ### Initial setup diff --git a/doc/english/web_views.md b/doc/english/web_views.md index 77ca27d4d..6fb33b912 100644 --- a/doc/english/web_views.md +++ b/doc/english/web_views.md @@ -1,836 +1,836 @@ -## Summary - -This is the guide to the iOS SDK of Adjust™ for iOS apps which are using web views. You can read more about Adjust™ at [adjust.com]. - -It provides a bridge from Javascript to native Objective-C calls (and vice versa) by using the [WebViewJavascriptBridge][web_view_js_bridge] plugin. This plugin is also licensed under `MIT License`. - -## Table of contents - -* [Example app](#example-app) -* [Basic integration](#basic-integration) - * [Add the SDK with the web bridge to your project](#sdk-add) - * [Add iOS frameworks](#sdk-frameworks) - * [Integrate the SDK into your app](#sdk-integrate) - * [Integrate AdjustBridge into your app](#bridge-integrate-app) - * [Integrate AdjustBridge into your web view](#bridge-integrate-web) - * [Basic setup](#basic-setup) - * [Adjust logging](#adjust-logging) - * [Build your app](#build-the-app) -* [Additional features](#additional-features) - * [Event tracking](#event-tracking) - * [Revenue tracking](#revenue-tracking) - * [Revenue deduplication](#revenue-deduplication) - * [Callback parameters](#callback-parameters) - * [Partner parameters](#partner-parameters) - * [Session parameters](#session-parameters) - * [Session callback parameters](#session-callback-parameters) - * [Session partner parameters](#session-partner-parameters) - * [Delay start](#delay-start) - * [Attribution callback](#attribution-callback) - * [Event and session callbacks](#event-session-callbacks) - * [Disable tracking](#disable-tracking) - * [Offline mode](#offline-mode) - * [Event buffering](#event-buffering) - * [GDPR right to be forgotten](#gdpr-forget-me) - * [Disable third-party sharing](#disable-third-party-sharing) - * [SDK signature](#sdk-signature) - * [Background tracking](#background-tracking) - * [Device IDs](#device-ids) - * [iOS Advertising Identifier](#di-idfa) - * [Adjust device identifier](#di-adid) - * [User attribution](#user-attribution) - * [Push token](#push-token) - * [Pre-installed trackers](#pre-installed-trackers) - * [Deep linking](#deeplinking) - * [Standard deep linking scenario](#deeplinking-standard) - * [Deep linking on iOS 8 and earlier](#deeplinking-setup-old) - * [Deep linking on iOS 9 and later](#deeplinking-setup-new) - * [Deferred deep linking scenario](#deeplinking-deferred) - * [Reattribution via deep links](#deeplinking-reattribution) -* [License](#license) - -## Example app - -In the repository, you can find an example [`iOS app with web view`][example-webview]. You can use this project to see how the Adjust SDK can be integrated. - -## Basic integration - -If you are migrating from the web bridge SDK v4.9.1 or previous, please follow [this migration guide](web_view_migration.md) when updating to this new version. - -We will describe the steps to integrate the Adjust SDK into your iOS project. We are going to assume that you are using Xcode for your iOS development. - -### Add the SDK with the web bridge to your project - -If you're using [CocoaPods][cocoapods], you can add the following line to your `Podfile` and continue from [this step](#sdk-integrate): - -```ruby -pod 'Adjust/WebBridge', '~> 4.30.0' -``` - ---- - -If you're using [Carthage][carthage], you can add following line to your `Cartfile` and continue from [this step](#sdk-frameworks): - -```ruby -github "adjust/ios_sdk" -``` - ---- - -You can also choose to integrate the Adjust SDK by adding it to your project as a framework. On the [releases page][releases] you can find the `AdjustSdkWebBridge.framework.zip` which contains dynamic framework. - -### Add iOS frameworks - -1. Select your project in the Project Navigator -2. In the left-hand side of the main view, select your target -3. In the `Build Phases` tab, expand the `Link Binary with Libraries` group -4. At the bottom of that section, select the `+` button -5. Select the `AdSupport.framework`, then the `Add` button -6. Repeat the same steps to add the `iAd.framework`, `CoreTelephony.framework` and `WebView.framework` -7. Change the `Status` of the frameworks to `Optional`. - -### Integrate the SDK into your app - -If you added the Adjust SDK via a Pod repository, you should use one of the following import statements in your app's source files: - -```objc -#import "AdjustBridge.h" -``` - ---- - -If you added the Adjust SDK as a static/dynamic framework or via Carthage, you should use the following import statement in your app's source files: - -```objc -#import -``` - -Next, we'll set up basic session tracking. - -### Integrate AdjustBridge into your app - -In the Project Navigator open the source file your View Controller. Add the `import` statement at the top of the file. In -the `viewDidLoad` or `viewWillAppear` method of your Web View Delegate add the following calls to `AdjustBridge`: - -```objc -#import "AdjustBridge.h" -// or #import - -- (void)viewWillAppear:(BOOL)animated { - WKWebView *webView = [[WKWebView alloc] initWithFrame:self.view.bounds]; - - // add @property (nonatomic, strong) AdjustBridge *adjustBridge; on your interface - [self.adjustBridge loadWKWebViewBridge:webView]; - // optionally you can add a web view delegate so that you can also capture its events - // [self.adjustBridge loadWKWebViewBridge:webView wkWebViewDelegate:(id)self]; -} - -// ... -``` - -You also can make use of the WebViewJavascriptBridge library we include, by using the `bridgeRegister` property of the `AdjustBridge` instance. -The register/call handler interface is similar to what WebViewJavascriptBridge does for ObjC. See [the library documentation](https://github.com/marcuswestin/WebViewJavascriptBridge#usage) for how to use it. - -### Integrate AdjustBrige into your web view - -To use the Javascript bridge on your web view, it must be configured like the `WebViewJavascriptBridge` plugin [README][wvjsb_readme] is advising in section `4`. Include the following Javascript code to intialize the Adjust iOS web bridge: - -```js -function setupWebViewJavascriptBridge(callback) { - if (window.WebViewJavascriptBridge) { - return callback(WebViewJavascriptBridge); - } - - if (window.WVJBCallbacks) { - return window.WVJBCallbacks.push(callback); - } - - window.WVJBCallbacks = [callback]; - - var WVJBIframe = document.createElement('iframe'); - WVJBIframe.style.display = 'none'; - WVJBIframe.src = 'https://__bridge_loaded__'; - document.documentElement.appendChild(WVJBIframe); - - setTimeout(function() { document.documentElement.removeChild(WVJBIframe) }, 0) -} -``` - -Take notice that the line `WVJBIframe.src = 'https://__bridge_loaded__';` was changed in version 4.11.6 from `WVJBIframe.src = 'wvjbscheme://__BRIDGE_LOADED__';` due to a change in the `WebViewJavascriptBridge` plugin. - -### Basic setup - -In the same HTML file, initialise the Adjust SDK inside the `setupWebViewJavascriptBridge` callback: - -```js -setupWebViewJavascriptBridge(function(bridge) { - // ... - - var yourAppToken = yourAppToken; - var environment = AdjustConfig.EnvironmentSandbox; - var adjustConfig = new AdjustConfig(yourAppToken, environment); - - Adjust.appDidLaunch(adjustConfig); - - // ... -}); -``` - -**Note**: Initialising the Adjust SDK like this is `very important`. Otherwise, you may encounter different kinds of issues as described in our [troubleshooting section](#ts-delayed-init). - -Replace `yourAppToken` with your app token. You can find this in your [dashboard]. - -Depending on whether you build your app for testing or for production, you must set `environment` with one of these values: - -```js -var environment = AdjustConfig.EnvironmentSandbox; -var environment = AdjustConfig.EnvironmentProduction; -``` - -**Important:** This value should be set to `AdjustConfig.EnvironmentSandbox` if and only if you or someone else is testing your app. Make sure to set the environment to `AdjustConfig.EnvironmentProduction` just before you publish the app. Set it back to `AdjustConfig.EnvironmentSandbox` when you start developing and testing it again. - -We use this environment to distinguish between real traffic and test traffic from test devices. It is very important that you keep this value meaningful at all times! This is especially important if you are tracking revenue. - -### Adjust logging - -You can increase or decrease the amount of logs that you see during testing by calling `setLogLevel:` on your `ADJConfig` instance with one of the following parameters: - -```js -adjustConfig.setLogLevel(AdjustConfig.LogLevelVerbose) // enable all logging -adjustConfig.setLogLevel(AdjustConfig.LogLevelDebug) // enable more logging -adjustConfig.setLogLevel(AdjustConfig.LogLevelInfo) // the default -adjustConfig.setLogLevel(AdjustConfig.LogLevelWarn) // disable info logging -adjustConfig.setLogLevel(AdjustConfig.LogLevelError) // disable warnings as well -adjustConfig.setLogLevel(AdjustConfig.LogLevelAssert) // disable errors as well -adjustConfig.setLogLevel(AdjustConfig.LogLevelSuppress) // disable all logging -``` - -If you don't want your app in production to display any logs coming from the Adjust SDK, then you should select `AdjustConfig.LogLevelSuppress` and in addition to that, initialise `AdjustConfig` object with another constructor where you should enable suppress log level mode with `true` in the third parameter: - -```js -setupWebViewJavascriptBridge(function(bridge) { - // ... - - var yourAppToken = yourAppToken; - var environment = AdjustConfig.EnvironmentSandbox; - var adjustConfig = new AdjustConfig(yourAppToken, environment, true); - - Adjust.appDidLaunch(adjustConfig); - - // ... -}); -``` - -### Build your app - -Build and run your app. If the build succeeds, you should carefully read the SDK logs in the console. After the app launches -for the first time, you should see the info log `Install tracked`. - -## Additional features - -Once you integrate the Adjust SDK into your project, you can take advantage of the following features. - -### Event tracking - -You can use Adjust to track events. Let's say you want to track every tap on a particular button. You would create a new event token in your [dashboard], which has an associated event token - looking something like `abc123`. In your button's `onclick` method you would then add the following lines to track the tap: - -```js -var adjustEvent = new AdjustEvent('abc123'); -Adjust.trackEvent(adjustEvent); -``` - -When tapping the button you should now see `Event tracked` in the logs. - -The event instance can be used to configure the event even more before tracking it. - -### Revenue tracking - -If your users can generate revenue by tapping on advertisements or making in-app purchases you can track those revenues with events. Lets say a tap is worth one Euro cent. You could then track the revenue event like this: - -```js -var adjustEvent = new AdjustEvent(eventToken); -adjustEvent.setRevenue(0.01, 'EUR'); -Adjust.trackEvent(adjustEvent); -``` - -This can be combined with callback parameters of course. - -When you set a currency token, Adjust will automatically convert the incoming revenues into a reporting revenue of your choice. Read more about [currency conversion here.][currency-conversion] - -You can read more about revenue and event tracking in the [event tracking guide][event-tracking-guide]. - -### Revenue deduplication - -You can also pass in an optional transaction ID to avoid tracking duplicate revenues. The last ten transaction IDs are remembered and revenue events with duplicate transaction IDs are skipped. This is especially useful for in-app purchase tracking. - -If you have access to the transaction indentifier from the web view, you can pass it to the `setTransactionId` method on the Adjust event object. That way you can avoid tracking revenue that is not actually being generated. - -```js -var adjustEvent = new AdjustEvent(eventToken); -adjustEvent.setTransactionId(transactionIdentifier); -Adjust.trackEvent(adjustEvent); -``` - -### Callback parameters - -You can register a callback URL for your events in your [dashboard]. We will send a GET request to that URL whenever the event gets tracked. You can add callback parameters to that event by calling `addCallbackParameter` on the event before tracking it. We will then append these parameters to your callback URL. - -For example, suppose you have registered the URL `http://www.adjust.com/callback` then track an event like this: - -```js -var adjustEvent = new AdjustEvent(eventToken); -adjustEvent.addCallbackParameter('key', 'value'); -adjustEvent.addCallbackParameter('foo', 'bar'); -Adjust.trackEvent(adjustEvent); -``` - -In that case we would track the event and send a request to: - - http://www.adjust.com/callback?key=value&foo=bar - -It should be mentioned that we support a variety of placeholders like `{idfa}` that can be used as parameter values. In the resulting callback this placeholder would be replaced with the ID for Advertisers of the current device. Also note that we don't store any of your custom parameters, but only append them to your callbacks. If you haven't registered a callback for an event, these parameters won't even be read. - -You can read more about using URL callbacks, including a full list of available values, in our [callbacks guide][callbacks-guide]. - -### Partner parameters - -You can also add parameters to be transmitted to network partners, for the integrations that have been activated in your Adjust dashboard. - -This works similarly to the callback parameters mentioned above, but can be added by calling the `addPartnerParameter` method on your `AdjustEvent` instance. - -```js -var adjustEvent = new AdjustEvent('abc123'); -adjustEvent.addPartnerParameter('key', 'value'); -adjustEvent.addPartnerParameter('foo', 'bar'); -Adjust.trackEvent(adjustEvent); -``` - -You can read more about special partners and these integrations in our [guide to special partners][special-partners]. - -### Session parameters - -Some parameters are saved to be sent in every event and session of the Adjust SDK. Once you have added any of these parameters, you don't need to add them every time, since they will be saved locally. If you add the same parameter twice, there will be no effect. - -If you want to send session parameters with the initial install event, they must be called before the Adjust SDK launches via `Adjust.appDidLaunch()`. If you need to send them with an install, but can only obtain the needed values after launch, it's possible to [delay](#delay-start) the first launch of the Adjust SDK to allow this behavior. - -### Session callback parameters - -The same callback parameters that are registered for [events](#callback-parameters) can be also saved to be sent in every event or session of the Adjust SDK. - -The session callback parameters have a similar interface of the event callback parameters. Instead of adding the key and it's value to an event, it's added through a call to `Adjust` method `addSessionCallbackParameter(key,value)`: - -```js -Adjust.addSessionCallbackParameter('foo', 'bar'); -``` - -The session callback parameters will be merged with the callback parameters added to an event. The callback parameters added to an event have precedence over the session callback parameters. Meaning that, when adding a callback parameter to an event with the same key to one added from the session, the value that prevails is the callback parameter added to the event. - -It's possible to remove a specific session callback parameter by passing the desiring key to the method `removeSessionCallbackParameter`. - -```js -Adjust.removeSessionCallbackParameter('foo'); -``` - -If you wish to remove all key and values from the session callback parameters, you can reset it with the method `resetSessionCallbackParameters`. - -```js -Adjust.resetSessionCallbackParameters(); -``` - -### Session partner parameters - -In the same way that there is [session callback parameters](#session-callback-parameters) that are sent every in event or session of the Adjust SDK, there is also session partner parameters. - -These will be transmitted to network partners, for the integrations that have been activated in your Adjust [dashboard]. - -The session partner parameters have a similar interface to the event partner parameters. Instead of adding the key and it's value to an event, it's added through a call to `Adjust` method `addSessionPartnerParameter:value:`: - -```js -Adjust.addSessionPartnerParameter('foo','bar'); -``` - -The session partner parameters will be merged with the partner parameters added to an event. The partner parameters added to an event have precedence over the session partner parameters. Meaning that, when adding a partner parameter to an event with the same key to one added from the session, the value that prevails is the partner parameter added to the event. - -It's possible to remove a specific session partner parameter by passing the desiring key to the method `removeSessionPartnerParameter`. - -```js -Adjust.removeSessionPartnerParameter('foo'); -``` - -If you wish to remove all key and values from the session partner parameters, you can reset it with the method `resetSessionPartnerParameters`. - -```js -Adjust.resetSessionPartnerParameters(); -``` - -### Delay start - -Delaying the start of the Adjust SDK allows your app some time to obtain session parameters, such as unique identifiers, to be send on install. - -Set the initial delay time in seconds with the method `setDelayStart` in the `AdjustConfig` instance: - -```js -adjustConfig.setDelayStart(5.5); -``` - -In this case this will make the Adjust SDK not send the initial install session and any event created for 5.5 seconds. After this time is expired or if you call `Adjust.sendFirstPackages()` in the meanwhile, every session parameter will be added to the delayed install session and events and the Adjust SDK will resume as usual. - -**The maximum delay start time of the Adjust SDK is 10 seconds**. - -### Attribution callback - -You can register a callback method to be notified of attribution changes. Due to the different sources considered for attribution, this information cannot by provided synchronously. - -Please make sure to consider our [applicable attribution data policies][attribution-data]. - -As the callback method is configured using the `AdjustConfig` instance, you should call `setAttributionCallback` before calling `Adjust.appDidLaunch(adjustConfig)`. - -```js -adjustConfig.setAttributionCallback(function(attribution) { - // In this example, we're just displaying alert with attribution content. - alert('Tracker token = ' + attribution.trackerToken + '\n' + - 'Tracker name = ' + attribution.trackerName + '\n' + - 'Network = ' + attribution.network + '\n' + - 'Campaign = ' + attribution.campaign + '\n' + - 'Adgroup = ' + attribution.adgroup + '\n' + - 'Creative = ' + attribution.creative + '\n' + - 'Click label = ' + attribution.clickLabel + '\n' + - 'Adid = ' + attribution.adid); -}); -``` - -The callback method will get triggered when the SDK receives final attribution data. Within the callback you have access to the `attribution` parameter. Here is a quick summary of its properties: - -- `var trackerToken` the tracker token of the current install. -- `var trackerName` the tracker name of the current install. -- `var network` the network grouping level of the current install. -- `var campaign` the campaign grouping level of the current install. -- `var adgroup` the ad group grouping level of the current install. -- `var creative` the creative grouping level of the current install. -- `var clickLabel` the click label of the current install. -- `var adid` the unique device identifier provided by attribution. - -If any value is unavailable, it will not be part of the of the attribution object. - -### Event and session callbacks - -You can register a callback to be notified when events or sessions are tracked. There are four callbacks: one for tracking successful events, one for tracking failed events, one for tracking successful sessions and one for tracking failed sessions. - -Follow these steps and implement the following callback methods to track successful events: - -```js -adjustConfig.setEventSuccessCallback(function(eventSuccess) { - // ... -}); -``` - -The following delegate callback function to track failed events: - -```js -adjustConfig.setEventFailureCallback(function(eventFailure) { - // ... -}); -``` - -To track successful sessions: - -```js -adjustConfig.setSessionSuccessCallback(function(sessionSuccess) { - // ... -}); -``` - -And to track failed sessions: - -```js -adjustConfig.setSessionFailureCallback(function(sessionFailure) { - // ... -}); -``` - -The callback methods will be called after the SDK tries to send a package to the server. Within the callback methods you have access to a response data object specifically for that callback. Here is a quick summary of the session response data properties: - -- `var message` the message from the server or the error logged by the SDK. -- `var timeStamp` timestamp from the server. -- `var adid` a unique device identifier provided by Adjust. -- `var jsonResponse` the JSON object with the response from the server. - -Both event response data objects contain: - -- `var eventToken` the event token, if the package tracked was an event. - -And both event and session failed objects also contain: - -- `var willRetry` indicates there will be an attempt to resend the package at a later time. - -### Disable tracking - -You can disable the Adjust SDK from tracking any activities of the current device by calling `setEnabled` with parameter `false`. **This setting is remembered between sessions**. - -```js -Adjust.setEnabled(false); -``` - -You can check if the Adjust SDK is currently enabled by calling the function `isEnabled`. - -```js -Adjust.isEnabled(function(isEnabled) { - if (isEnabled) { - // SDK is enabled. - } else { - // SDK is disabled. - } -}); -``` - -It is always possible to activate the Adjust SDK by invoking `setEnabled` with the enabled parameter as `true`. - -### Offline mode - -You can put the Adjust SDK in offline mode to suspend transmission to our servers while retaining tracked data to be sent later. While in offline mode, all information is saved in a file, so be careful not to trigger too many events while in offline mode. - -You can activate offline mode by calling `setOfflineMode` with the parameter `true`. - -```js -Adjust.setOfflineMode(true); -``` - -Conversely, you can deactivate offline mode by calling `setOfflineMode` with `false`. When the Adjust SDK is put back in online mode, all saved information is send to our servers with the correct time information. - -Unlike disabling tracking, this setting is **not remembered bettween sessions**. This means that the SDK is in online mode whenever it is started, even if the app was terminated in offline mode. - -### Event buffering - -If your app makes heavy use of event tracking, you might want to delay some network requests in order to send them in one batch every minute. You can enable event buffering with your `AdjustConfig` instance: - -```js -adjustConfig.setEventBufferingEnabled(true); -``` - -### GDPR right to be forgotten - -In accordance with article 17 of the EU's General Data Protection Regulation (GDPR), you can notify Adjust when a user has exercised their right to be forgotten. Calling the following method will instruct the Adjust SDK to communicate the user's choice to be forgotten to the Adjust backend: - -```js -Adjust.gdprForgetMe(); -``` - -Upon receiving this information, Adjust will erase the user's data and the Adjust SDK will stop tracking the user. No requests from this device will be sent to Adjust in the future. - - -### Disable third-party sharing - -You can now notify Adjust when a user has exercised their right to stop sharing their data with partners for marketing partners, but has allowed it to be shared for statistics purposes. - -Call the following method to instruct the Adjust SDK to communicate the user's choice to disable data sharing to the Adjust backend: - -```js -Adjust.disableThirdPartySharing(); -``` - -Upon receiving this information, Adjust will block the sharing of that specific user's data to partners and the Adjust SDK will continue to work as usual. - -### SDK signature - -The Adjust SDK signature is enabled on a client-by-client basis. If you are interested in using this feature, please contact your account manager. - -If the SDK signature has already been enabled on your account and you have access to App Secrets in your Adjust Dashboard, please use the method below to integrate the SDK signature into your app. - -An App Secret is set by calling `setAppSecret` on your `AdjustConfig` instance: - -```js -adjustConfig.setAppSecret(secretId, info1, info2, info3, info4); -``` - -### Background tracking - -The default behaviour of the Adjust SDK is to pause sending network requests while the app is in the background. You can change this behaviour in your `AdjustConfig` instance: - -```js -adjustConfig.setSendInBackground(true); -``` - -If nothing is set, sending in background is **disabled by default**. - -### Device IDs - -The Adjust SDK offers you possibility to obtain some of the device identifiers. - -### iOS Advertising Identifier - -Certain services (such as Google Analytics) require you to coordinate device and client IDs in order to prevent duplicate reporting. - -To obtain the device identifier IDFA, call the function `getIdfa`: - -```js -Adjust.getIdfa(function(idfa) { - // ... -}); -``` - -### Adjust device identifier - -For each device with your app installed, Adjust backend generates unique **adjust device identifier** (**adid**). In order to obtain this identifier, you can make a call to the following method on the `Adjust` instance: - -```js -var adid = Adjust.getAdid(); -``` - -**Note**: Information about the **adid** is available after the app's installation has been tracked by the Adjust backend. From that moment on, the Adjust SDK has information about the device **adid** and you can access it with this method. So, **it is not possible** to access the **adid** before the SDK has been initialised and the installation of your app has been tracked successfully. - -### User attribution - -The attribution callback will be triggered as described in the [attribution callback section](#attribution-callback), providing you with the information about any new attribution when ever it changes. In any other case, where you want to access information about your user's current attribution, you can make a call to the following method of the `Adjust` object: - -```js -var attribution = Adjust.getAttribution(); -``` - -**Note**: Information about current attribution is available after app installation has been tracked by the Adjust backend and attribution callback has been initially triggered. From that moment on, Adjust SDK has information about your user's attribution and you can access it with this method. So, **it is not possible** to access user's attribution value before the SDK has been initialised and attribution callback has been initially triggered. - -### Push token - -Push tokens are used for Audience Builder and client callbacks, and they are required for uninstall and reinstall tracking. - -To send us the push notification token, add the following call to `Adjust` in the `didRegisterForRemoteNotificationsWithDeviceToken` of your app delegate: - -```objc -#import "Adjust.h" -// or #import - -- (void)application:(UIApplication *)app didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken { - [Adjust setDeviceToken:deviceToken]; -} -``` - -Or, if you have access to the push token from the web view, you can instead call the `setDeviceToken` method in the `Adjust` object in Javascript: - -```js -Adjust.setDeviceToken(deviceToken); -``` - -### Pre-installed trackers - -If you want to use the Adjust SDK to recognize users that found your app pre-installed on their device, follow these steps. - -1. Create a new tracker in your [dashboard]. -2. Open your app delegate and add set the default tracker of your `AdjustConfig` instance: - - ```js - adjustConfig.setDefaultTracker(trackerToken); - ``` - - Replace `trackerToken` with the tracker token you created in step 2. Please note that the dashboard displays a tracker - URL (including `http://app.adjust.com/`). In your source code, you should specify only the six-character token and not - the entire URL. - -### Deep linking - -If you are using the Adjust tracker URL with an option to deep link into your app from the URL, there is the possibility to get info about the deep link URL and its content. Hitting the URL can happen when the user has your app already installed (standard deep linking scenario) or if they don't have the app on their device (deferred deep linking scenario). Both of these scenarios are supported by the Adjust SDK and in both cases the deep link URL will be provided to you after you app has been started after hitting the tracker URL. In order to use this feature in your app, you need to set it up properly. - -### Standard deep linking scenario - -If your user already has the app installed and hits the tracker URL with deep link information in it, your application will be opened and the content of the deep link will be sent to your app so that you can parse it and decide what to do next. With introduction of iOS 9, Apple has changed the way how deep linking should be handled in the app. Depending on which scenario you want to use for your app (or if you want to use them both to support wide range of devices), you need to set up your app to handle one or both of the following scenarios. - -### Deep linking on iOS 8 and earlier - -Deep linking on iOS 8 and earlier devices is being done with usage of a custom URL scheme setting. You need to pick a custom URL scheme name which your app will be in charge for opening. This scheme name will also be used in the Adjust tracker URL as part of the `deep_link` parameter. In order to set this in your app, open your `Info.plist` file and add new `URL types` row to it. In there, as `URL identifier` write you app's bundle ID and under `URL schemes` add scheme name(s) which you want your app to handle. In the example below, we have chosen that our app should handle the `adjustExample` scheme name. - -![][custom-url-scheme] - -After this has been set up, your app will be opened after you click the Adjust tracker URL with `deep_link` parameter which contains the scheme name which you have chosen. After app is opened, `openURL` method of your `AppDelegate` class will be triggered and the place where the content of the `deep_link` parameter from the tracker URL will be delivered. If you want to access the content of the deep link, override this method. - -```objc -#import "Adjust.h" -// or #import - -- (BOOL)application:(UIApplication *)application openURL:(NSURL *)url - sourceApplication:(NSString *)sourceApplication annotation:(id)annotation { - // url object contains your deep link content - - // Apply your logic to determine the return value of this method - return YES; - // or - // return NO; -} -``` - -With this setup, you have successfully set up deep linking handling for iOS devices with iOS 8 and earlier versions. - -### Deep linking on iOS 9 and later - -In order to set deep linking support for iOS 9 and later devices, you need to enable your app to handle Apple universal links. To find out more about universal links and how their setup looks like, you can check [here][universal-links]. - -Adjust is taking care of lots of things to do with universal links behind the scenes. But, in order to support universal links with the Adjust, you need to perform small setup for universal links in the Adjust dashboard. For more information on that should be done, please consult our official [docs][universal-links-guide]. - -Once you have successfully enabled the universal links feature in the dashboard, you need to do this in your app as well: - -After enabling `Associated Domains` for your app in Apple Developer Portal, you need to do the same thing in your app's Xcode project. After enabling `Assciated Domains`, add the universal link which was generated for you in the Adjust dashboard in the `Domains` section by prefixing it with `applinks:` and make sure that you also remove the `http(s)` part of the universal link. - -![][associated-domains-applinks] - -After this has been set up, your app will be opened after you click the Adjust tracker universal link. After app is opened, `continueUserActivity` method of your `AppDelegate` class will be triggered and the place where the content of the universal link URL will be delivered. If you want to access the content of the deep link, override this method. - -``` objc -#import "Adjust.h" -// or #import - -- (BOOL)application:(UIApplication *)application continueUserActivity:(NSUserActivity *)userActivity - restorationHandler:(void (^)(NSArray *restorableObjects))restorationHandler { - if ([[userActivity activityType] isEqualToString:NSUserActivityTypeBrowsingWeb]) { - NSURL *url = [userActivity webpageURL]; - - // url object contains your universal link content - } - - // Apply your logic to determine the return value of this method - return YES; - // or - // return NO; -} -``` - -With this setup, you have successfully set up deep linking handling for iOS devices with iOS 9 and later versions. - -We provide a helper function that allows you to convert a universal link to an old style deep link URL, in case you had some custom logic in your code which was always expecting deep link info to arrive in old style custom URL scheme format. You can call this method with universal link and the custom URL scheme name which you would like to see your deep link prefixed with and we will generate the custom URL scheme deep link for you: - -``` objc -#import "Adjust.h" -// or #import - -- (BOOL)application:(UIApplication *)application continueUserActivity:(NSUserActivity *)userActivity - restorationHandler:(void (^)(NSArray *restorableObjects))restorationHandler { - if ([[userActivity activityType] isEqualToString:NSUserActivityTypeBrowsingWeb]) { - NSURL *url = [userActivity webpageURL]; - - NSURL *oldStyleDeeplink = [Adjust convertUniversalLink:url scheme:@"adjustExample"]; - } - - // Apply your logic to determine the return value of this method - return YES; - // or - // return NO; -} -``` - -### Deferred deep linking scenario - -You can register a callback to be notified before a deferred deep link is opened. You can configure the callback on the `AdjustConfig` instance: - -```js -adjustConfig.setDeferredDeeplinkCallback(function(deferredDeeplink) { - // ... -}); -``` -The callback function will be called after the SDK receives a deffered deep link from our server and before opening it. - -If this callback is not implemented, **the Adjust SDK will always try to open the deep link by default**. - -With another setting on the `AdjustConfig` instance, you have the possibility to decide whether the Adjust SDK will open this deeplink or not. You could, for example, not allow the SDK to open the deep link at the current moment, save it, and open it yourself later. You can do this by calling the `setOpenDeferredDeeplink` method: - -```js -// Default setting. The SDK will open the deeplink after the deferred deeplink callback -adjustConfig.setOpenDeferredDeeplink(true); - -// Or if you don't want our SDK to open the deeplink: -adjustConfig.setOpenDeferredDeeplink(false); -``` - -### Reattribution via deep links - -Adjust enables you to run re-engagement campaigns with usage of deep links. For more information on how to do that, please check our [official docs][reattribution-with-deeplinks]. - -If you are using this feature, in order for your user to be properly reattributed, you need to make one additional call to the Adjust SDK in your app. - -Once you have received deep link content information in your app, add a call to the `appWillOpenUrl` method. By making this call, the Adjust SDK will try to find if there is any new attribution info inside of the deep link and if any, it will be sent to the Adjust backend. If your user should be reattributed due to a click on the Adjust tracker URL with deep link content in it, you will see the [attribution callback](#attribution-callback) in your app being triggered with new attribution info for this user. - -The call to `appWillOpenUrl` should be done like this to support deep linking reattributions in all iOS versions: - -```objc -#import "Adjust.h" -// or #import - -- (BOOL)application:(UIApplication *)application openURL:(NSURL *)url - sourceApplication:(NSString *)sourceApplication annotation:(id)annotation { - // url object contains your deep link content - - [Adjust appWillOpenUrl:url]; - - // Apply your logic to determine the return value of this method - return YES; - // or - // return NO; -} -``` - -``` objc -#import "Adjust.h" -// or #import - -- (BOOL)application:(UIApplication *)application continueUserActivity:(NSUserActivity *)userActivity - restorationHandler:(void (^)(NSArray *restorableObjects))restorationHandler { - if ([[userActivity activityType] isEqualToString:NSUserActivityTypeBrowsingWeb]) { - NSURL url = [userActivity webpageURL]; - - [Adjust appWillOpenUrl:url]; - } - - // Apply your logic to determine the return value of this method - return YES; - // or - // return NO; -} -``` - -If you have access to the deeplink url in the web view, you can call the `appWillOpenUrl` method from the `Adjust` object from Javascript: - -```js -Adjust.appWillOpenUrl(deeplinkUrl); -``` - - -[dashboard]: http://adjust.com -[adjust.com]: http://adjust.com - -[releases]: https://github.com/adjust/ios_sdk/releases -[carthage]: https://github.com/Carthage/Carthage -[cocoapods]: http://cocoapods.org - -[wvjsb_readme]: https://github.com/marcuswestin/WebViewJavascriptBridge#usage -[ios_sdk_ulinks]: https://github.com/adjust/ios_sdk/#universal-links -[example-webview]: https://github.com/adjust/ios_sdk/tree/master/examples/AdjustExample-WebView -[callbacks-guide]: https://docs.adjust.com/en/callbacks -[attribution-data]: https://github.com/adjust/sdks/blob/master/doc/attribution-data.md -[special-partners]: https://docs.adjust.com/en/special-partners -[basic_integration]: https://github.com/adjust/ios_sdk/#basic-integration -[web_view_js_bridge]: https://github.com/marcuswestin/WebViewJavascriptBridge -[currency-conversion]: https://docs.adjust.com/en/event-tracking/#tracking-purchases-in-different-currencies -[event-tracking-guide]: https://docs.adjust.com/en/event-tracking/#reference-tracking-purchases-and-revenues -[reattribution-deeplinks]: https://docs.adjust.com/en/deeplinking/#manually-appending-attribution-data-to-a-deep-link - -[custom-url-scheme]: https://raw.github.com/adjust/sdks/master/Resources/ios/custom-url-scheme.png -[associated-domains-applinks]: https://raw.github.com/adjust/sdks/master/Resources/ios/associated-domains-applinks.png - -## License - -The Adjust SDK is licensed under the MIT License. - -Copyright (c) 2012-2018 Adjust GmbH, http://www.adjust.com - -Permission is hereby granted, free of charge, to any person obtaining a copy of -this software and associated documentation files (the "Software"), to deal in -the Software without restriction, including without limitation the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies -of the Software, and to permit persons to whom the Software is furnished to do -so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +## Summary + +This is the guide to the iOS SDK of Adjust™ for iOS apps which are using web views. You can read more about Adjust™ at [adjust.com]. + +It provides a bridge from Javascript to native Objective-C calls (and vice versa) by using the [WebViewJavascriptBridge][web_view_js_bridge] plugin. This plugin is also licensed under `MIT License`. + +## Table of contents + +* [Example app](#example-app) +* [Basic integration](#basic-integration) + * [Add the SDK with the web bridge to your project](#sdk-add) + * [Add iOS frameworks](#sdk-frameworks) + * [Integrate the SDK into your app](#sdk-integrate) + * [Integrate AdjustBridge into your app](#bridge-integrate-app) + * [Integrate AdjustBridge into your web view](#bridge-integrate-web) + * [Basic setup](#basic-setup) + * [Adjust logging](#adjust-logging) + * [Build your app](#build-the-app) +* [Additional features](#additional-features) + * [Event tracking](#event-tracking) + * [Revenue tracking](#revenue-tracking) + * [Revenue deduplication](#revenue-deduplication) + * [Callback parameters](#callback-parameters) + * [Partner parameters](#partner-parameters) + * [Session parameters](#session-parameters) + * [Session callback parameters](#session-callback-parameters) + * [Session partner parameters](#session-partner-parameters) + * [Delay start](#delay-start) + * [Attribution callback](#attribution-callback) + * [Event and session callbacks](#event-session-callbacks) + * [Disable tracking](#disable-tracking) + * [Offline mode](#offline-mode) + * [Event buffering](#event-buffering) + * [GDPR right to be forgotten](#gdpr-forget-me) + * [Disable third-party sharing](#disable-third-party-sharing) + * [SDK signature](#sdk-signature) + * [Background tracking](#background-tracking) + * [Device IDs](#device-ids) + * [iOS Advertising Identifier](#di-idfa) + * [Adjust device identifier](#di-adid) + * [User attribution](#user-attribution) + * [Push token](#push-token) + * [Pre-installed trackers](#pre-installed-trackers) + * [Deep linking](#deeplinking) + * [Standard deep linking scenario](#deeplinking-standard) + * [Deep linking on iOS 8 and earlier](#deeplinking-setup-old) + * [Deep linking on iOS 9 and later](#deeplinking-setup-new) + * [Deferred deep linking scenario](#deeplinking-deferred) + * [Reattribution via deep links](#deeplinking-reattribution) +* [License](#license) + +## Example app + +In the repository, you can find an example [`iOS app with web view`][example-webview]. You can use this project to see how the Adjust SDK can be integrated. + +## Basic integration + +If you are migrating from the web bridge SDK v4.9.1 or previous, please follow [this migration guide](web_view_migration.md) when updating to this new version. + +We will describe the steps to integrate the Adjust SDK into your iOS project. We are going to assume that you are using Xcode for your iOS development. + +### Add the SDK with the web bridge to your project + +If you're using [CocoaPods][cocoapods], you can add the following line to your `Podfile` and continue from [this step](#sdk-integrate): + +```ruby +pod 'Adjust/WebBridge', '~> 4.31.0' +``` + +--- + +If you're using [Carthage][carthage], you can add following line to your `Cartfile` and continue from [this step](#sdk-frameworks): + +```ruby +github "adjust/ios_sdk" +``` + +--- + +You can also choose to integrate the Adjust SDK by adding it to your project as a framework. On the [releases page][releases] you can find the `AdjustSdkWebBridge.framework.zip` which contains dynamic framework. + +### Add iOS frameworks + +1. Select your project in the Project Navigator +2. In the left-hand side of the main view, select your target +3. In the `Build Phases` tab, expand the `Link Binary with Libraries` group +4. At the bottom of that section, select the `+` button +5. Select the `AdSupport.framework`, then the `Add` button +6. Repeat the same steps to add the `iAd.framework`, `CoreTelephony.framework` and `WebView.framework` +7. Change the `Status` of the frameworks to `Optional`. + +### Integrate the SDK into your app + +If you added the Adjust SDK via a Pod repository, you should use one of the following import statements in your app's source files: + +```objc +#import "AdjustBridge.h" +``` + +--- + +If you added the Adjust SDK as a static/dynamic framework or via Carthage, you should use the following import statement in your app's source files: + +```objc +#import +``` + +Next, we'll set up basic session tracking. + +### Integrate AdjustBridge into your app + +In the Project Navigator open the source file your View Controller. Add the `import` statement at the top of the file. In +the `viewDidLoad` or `viewWillAppear` method of your Web View Delegate add the following calls to `AdjustBridge`: + +```objc +#import "AdjustBridge.h" +// or #import + +- (void)viewWillAppear:(BOOL)animated { + WKWebView *webView = [[WKWebView alloc] initWithFrame:self.view.bounds]; + + // add @property (nonatomic, strong) AdjustBridge *adjustBridge; on your interface + [self.adjustBridge loadWKWebViewBridge:webView]; + // optionally you can add a web view delegate so that you can also capture its events + // [self.adjustBridge loadWKWebViewBridge:webView wkWebViewDelegate:(id)self]; +} + +// ... +``` + +You also can make use of the WebViewJavascriptBridge library we include, by using the `bridgeRegister` property of the `AdjustBridge` instance. +The register/call handler interface is similar to what WebViewJavascriptBridge does for ObjC. See [the library documentation](https://github.com/marcuswestin/WebViewJavascriptBridge#usage) for how to use it. + +### Integrate AdjustBrige into your web view + +To use the Javascript bridge on your web view, it must be configured like the `WebViewJavascriptBridge` plugin [README][wvjsb_readme] is advising in section `4`. Include the following Javascript code to intialize the Adjust iOS web bridge: + +```js +function setupWebViewJavascriptBridge(callback) { + if (window.WebViewJavascriptBridge) { + return callback(WebViewJavascriptBridge); + } + + if (window.WVJBCallbacks) { + return window.WVJBCallbacks.push(callback); + } + + window.WVJBCallbacks = [callback]; + + var WVJBIframe = document.createElement('iframe'); + WVJBIframe.style.display = 'none'; + WVJBIframe.src = 'https://__bridge_loaded__'; + document.documentElement.appendChild(WVJBIframe); + + setTimeout(function() { document.documentElement.removeChild(WVJBIframe) }, 0) +} +``` + +Take notice that the line `WVJBIframe.src = 'https://__bridge_loaded__';` was changed in version 4.11.6 from `WVJBIframe.src = 'wvjbscheme://__BRIDGE_LOADED__';` due to a change in the `WebViewJavascriptBridge` plugin. + +### Basic setup + +In the same HTML file, initialise the Adjust SDK inside the `setupWebViewJavascriptBridge` callback: + +```js +setupWebViewJavascriptBridge(function(bridge) { + // ... + + var yourAppToken = yourAppToken; + var environment = AdjustConfig.EnvironmentSandbox; + var adjustConfig = new AdjustConfig(yourAppToken, environment); + + Adjust.appDidLaunch(adjustConfig); + + // ... +}); +``` + +**Note**: Initialising the Adjust SDK like this is `very important`. Otherwise, you may encounter different kinds of issues as described in our [troubleshooting section](#ts-delayed-init). + +Replace `yourAppToken` with your app token. You can find this in your [dashboard]. + +Depending on whether you build your app for testing or for production, you must set `environment` with one of these values: + +```js +var environment = AdjustConfig.EnvironmentSandbox; +var environment = AdjustConfig.EnvironmentProduction; +``` + +**Important:** This value should be set to `AdjustConfig.EnvironmentSandbox` if and only if you or someone else is testing your app. Make sure to set the environment to `AdjustConfig.EnvironmentProduction` just before you publish the app. Set it back to `AdjustConfig.EnvironmentSandbox` when you start developing and testing it again. + +We use this environment to distinguish between real traffic and test traffic from test devices. It is very important that you keep this value meaningful at all times! This is especially important if you are tracking revenue. + +### Adjust logging + +You can increase or decrease the amount of logs that you see during testing by calling `setLogLevel:` on your `ADJConfig` instance with one of the following parameters: + +```js +adjustConfig.setLogLevel(AdjustConfig.LogLevelVerbose) // enable all logging +adjustConfig.setLogLevel(AdjustConfig.LogLevelDebug) // enable more logging +adjustConfig.setLogLevel(AdjustConfig.LogLevelInfo) // the default +adjustConfig.setLogLevel(AdjustConfig.LogLevelWarn) // disable info logging +adjustConfig.setLogLevel(AdjustConfig.LogLevelError) // disable warnings as well +adjustConfig.setLogLevel(AdjustConfig.LogLevelAssert) // disable errors as well +adjustConfig.setLogLevel(AdjustConfig.LogLevelSuppress) // disable all logging +``` + +If you don't want your app in production to display any logs coming from the Adjust SDK, then you should select `AdjustConfig.LogLevelSuppress` and in addition to that, initialise `AdjustConfig` object with another constructor where you should enable suppress log level mode with `true` in the third parameter: + +```js +setupWebViewJavascriptBridge(function(bridge) { + // ... + + var yourAppToken = yourAppToken; + var environment = AdjustConfig.EnvironmentSandbox; + var adjustConfig = new AdjustConfig(yourAppToken, environment, true); + + Adjust.appDidLaunch(adjustConfig); + + // ... +}); +``` + +### Build your app + +Build and run your app. If the build succeeds, you should carefully read the SDK logs in the console. After the app launches +for the first time, you should see the info log `Install tracked`. + +## Additional features + +Once you integrate the Adjust SDK into your project, you can take advantage of the following features. + +### Event tracking + +You can use Adjust to track events. Let's say you want to track every tap on a particular button. You would create a new event token in your [dashboard], which has an associated event token - looking something like `abc123`. In your button's `onclick` method you would then add the following lines to track the tap: + +```js +var adjustEvent = new AdjustEvent('abc123'); +Adjust.trackEvent(adjustEvent); +``` + +When tapping the button you should now see `Event tracked` in the logs. + +The event instance can be used to configure the event even more before tracking it. + +### Revenue tracking + +If your users can generate revenue by tapping on advertisements or making in-app purchases you can track those revenues with events. Lets say a tap is worth one Euro cent. You could then track the revenue event like this: + +```js +var adjustEvent = new AdjustEvent(eventToken); +adjustEvent.setRevenue(0.01, 'EUR'); +Adjust.trackEvent(adjustEvent); +``` + +This can be combined with callback parameters of course. + +When you set a currency token, Adjust will automatically convert the incoming revenues into a reporting revenue of your choice. Read more about [currency conversion here.][currency-conversion] + +You can read more about revenue and event tracking in the [event tracking guide][event-tracking-guide]. + +### Revenue deduplication + +You can also pass in an optional transaction ID to avoid tracking duplicate revenues. The last ten transaction IDs are remembered and revenue events with duplicate transaction IDs are skipped. This is especially useful for in-app purchase tracking. + +If you have access to the transaction indentifier from the web view, you can pass it to the `setTransactionId` method on the Adjust event object. That way you can avoid tracking revenue that is not actually being generated. + +```js +var adjustEvent = new AdjustEvent(eventToken); +adjustEvent.setTransactionId(transactionIdentifier); +Adjust.trackEvent(adjustEvent); +``` + +### Callback parameters + +You can register a callback URL for your events in your [dashboard]. We will send a GET request to that URL whenever the event gets tracked. You can add callback parameters to that event by calling `addCallbackParameter` on the event before tracking it. We will then append these parameters to your callback URL. + +For example, suppose you have registered the URL `http://www.adjust.com/callback` then track an event like this: + +```js +var adjustEvent = new AdjustEvent(eventToken); +adjustEvent.addCallbackParameter('key', 'value'); +adjustEvent.addCallbackParameter('foo', 'bar'); +Adjust.trackEvent(adjustEvent); +``` + +In that case we would track the event and send a request to: + + http://www.adjust.com/callback?key=value&foo=bar + +It should be mentioned that we support a variety of placeholders like `{idfa}` that can be used as parameter values. In the resulting callback this placeholder would be replaced with the ID for Advertisers of the current device. Also note that we don't store any of your custom parameters, but only append them to your callbacks. If you haven't registered a callback for an event, these parameters won't even be read. + +You can read more about using URL callbacks, including a full list of available values, in our [callbacks guide][callbacks-guide]. + +### Partner parameters + +You can also add parameters to be transmitted to network partners, for the integrations that have been activated in your Adjust dashboard. + +This works similarly to the callback parameters mentioned above, but can be added by calling the `addPartnerParameter` method on your `AdjustEvent` instance. + +```js +var adjustEvent = new AdjustEvent('abc123'); +adjustEvent.addPartnerParameter('key', 'value'); +adjustEvent.addPartnerParameter('foo', 'bar'); +Adjust.trackEvent(adjustEvent); +``` + +You can read more about special partners and these integrations in our [guide to special partners][special-partners]. + +### Session parameters + +Some parameters are saved to be sent in every event and session of the Adjust SDK. Once you have added any of these parameters, you don't need to add them every time, since they will be saved locally. If you add the same parameter twice, there will be no effect. + +If you want to send session parameters with the initial install event, they must be called before the Adjust SDK launches via `Adjust.appDidLaunch()`. If you need to send them with an install, but can only obtain the needed values after launch, it's possible to [delay](#delay-start) the first launch of the Adjust SDK to allow this behavior. + +### Session callback parameters + +The same callback parameters that are registered for [events](#callback-parameters) can be also saved to be sent in every event or session of the Adjust SDK. + +The session callback parameters have a similar interface of the event callback parameters. Instead of adding the key and it's value to an event, it's added through a call to `Adjust` method `addSessionCallbackParameter(key,value)`: + +```js +Adjust.addSessionCallbackParameter('foo', 'bar'); +``` + +The session callback parameters will be merged with the callback parameters added to an event. The callback parameters added to an event have precedence over the session callback parameters. Meaning that, when adding a callback parameter to an event with the same key to one added from the session, the value that prevails is the callback parameter added to the event. + +It's possible to remove a specific session callback parameter by passing the desiring key to the method `removeSessionCallbackParameter`. + +```js +Adjust.removeSessionCallbackParameter('foo'); +``` + +If you wish to remove all key and values from the session callback parameters, you can reset it with the method `resetSessionCallbackParameters`. + +```js +Adjust.resetSessionCallbackParameters(); +``` + +### Session partner parameters + +In the same way that there is [session callback parameters](#session-callback-parameters) that are sent every in event or session of the Adjust SDK, there is also session partner parameters. + +These will be transmitted to network partners, for the integrations that have been activated in your Adjust [dashboard]. + +The session partner parameters have a similar interface to the event partner parameters. Instead of adding the key and it's value to an event, it's added through a call to `Adjust` method `addSessionPartnerParameter:value:`: + +```js +Adjust.addSessionPartnerParameter('foo','bar'); +``` + +The session partner parameters will be merged with the partner parameters added to an event. The partner parameters added to an event have precedence over the session partner parameters. Meaning that, when adding a partner parameter to an event with the same key to one added from the session, the value that prevails is the partner parameter added to the event. + +It's possible to remove a specific session partner parameter by passing the desiring key to the method `removeSessionPartnerParameter`. + +```js +Adjust.removeSessionPartnerParameter('foo'); +``` + +If you wish to remove all key and values from the session partner parameters, you can reset it with the method `resetSessionPartnerParameters`. + +```js +Adjust.resetSessionPartnerParameters(); +``` + +### Delay start + +Delaying the start of the Adjust SDK allows your app some time to obtain session parameters, such as unique identifiers, to be send on install. + +Set the initial delay time in seconds with the method `setDelayStart` in the `AdjustConfig` instance: + +```js +adjustConfig.setDelayStart(5.5); +``` + +In this case this will make the Adjust SDK not send the initial install session and any event created for 5.5 seconds. After this time is expired or if you call `Adjust.sendFirstPackages()` in the meanwhile, every session parameter will be added to the delayed install session and events and the Adjust SDK will resume as usual. + +**The maximum delay start time of the Adjust SDK is 10 seconds**. + +### Attribution callback + +You can register a callback method to be notified of attribution changes. Due to the different sources considered for attribution, this information cannot by provided synchronously. + +Please make sure to consider our [applicable attribution data policies][attribution-data]. + +As the callback method is configured using the `AdjustConfig` instance, you should call `setAttributionCallback` before calling `Adjust.appDidLaunch(adjustConfig)`. + +```js +adjustConfig.setAttributionCallback(function(attribution) { + // In this example, we're just displaying alert with attribution content. + alert('Tracker token = ' + attribution.trackerToken + '\n' + + 'Tracker name = ' + attribution.trackerName + '\n' + + 'Network = ' + attribution.network + '\n' + + 'Campaign = ' + attribution.campaign + '\n' + + 'Adgroup = ' + attribution.adgroup + '\n' + + 'Creative = ' + attribution.creative + '\n' + + 'Click label = ' + attribution.clickLabel + '\n' + + 'Adid = ' + attribution.adid); +}); +``` + +The callback method will get triggered when the SDK receives final attribution data. Within the callback you have access to the `attribution` parameter. Here is a quick summary of its properties: + +- `var trackerToken` the tracker token of the current install. +- `var trackerName` the tracker name of the current install. +- `var network` the network grouping level of the current install. +- `var campaign` the campaign grouping level of the current install. +- `var adgroup` the ad group grouping level of the current install. +- `var creative` the creative grouping level of the current install. +- `var clickLabel` the click label of the current install. +- `var adid` the unique device identifier provided by attribution. + +If any value is unavailable, it will not be part of the of the attribution object. + +### Event and session callbacks + +You can register a callback to be notified when events or sessions are tracked. There are four callbacks: one for tracking successful events, one for tracking failed events, one for tracking successful sessions and one for tracking failed sessions. + +Follow these steps and implement the following callback methods to track successful events: + +```js +adjustConfig.setEventSuccessCallback(function(eventSuccess) { + // ... +}); +``` + +The following delegate callback function to track failed events: + +```js +adjustConfig.setEventFailureCallback(function(eventFailure) { + // ... +}); +``` + +To track successful sessions: + +```js +adjustConfig.setSessionSuccessCallback(function(sessionSuccess) { + // ... +}); +``` + +And to track failed sessions: + +```js +adjustConfig.setSessionFailureCallback(function(sessionFailure) { + // ... +}); +``` + +The callback methods will be called after the SDK tries to send a package to the server. Within the callback methods you have access to a response data object specifically for that callback. Here is a quick summary of the session response data properties: + +- `var message` the message from the server or the error logged by the SDK. +- `var timeStamp` timestamp from the server. +- `var adid` a unique device identifier provided by Adjust. +- `var jsonResponse` the JSON object with the response from the server. + +Both event response data objects contain: + +- `var eventToken` the event token, if the package tracked was an event. + +And both event and session failed objects also contain: + +- `var willRetry` indicates there will be an attempt to resend the package at a later time. + +### Disable tracking + +You can disable the Adjust SDK from tracking any activities of the current device by calling `setEnabled` with parameter `false`. **This setting is remembered between sessions**. + +```js +Adjust.setEnabled(false); +``` + +You can check if the Adjust SDK is currently enabled by calling the function `isEnabled`. + +```js +Adjust.isEnabled(function(isEnabled) { + if (isEnabled) { + // SDK is enabled. + } else { + // SDK is disabled. + } +}); +``` + +It is always possible to activate the Adjust SDK by invoking `setEnabled` with the enabled parameter as `true`. + +### Offline mode + +You can put the Adjust SDK in offline mode to suspend transmission to our servers while retaining tracked data to be sent later. While in offline mode, all information is saved in a file, so be careful not to trigger too many events while in offline mode. + +You can activate offline mode by calling `setOfflineMode` with the parameter `true`. + +```js +Adjust.setOfflineMode(true); +``` + +Conversely, you can deactivate offline mode by calling `setOfflineMode` with `false`. When the Adjust SDK is put back in online mode, all saved information is send to our servers with the correct time information. + +Unlike disabling tracking, this setting is **not remembered bettween sessions**. This means that the SDK is in online mode whenever it is started, even if the app was terminated in offline mode. + +### Event buffering + +If your app makes heavy use of event tracking, you might want to delay some network requests in order to send them in one batch every minute. You can enable event buffering with your `AdjustConfig` instance: + +```js +adjustConfig.setEventBufferingEnabled(true); +``` + +### GDPR right to be forgotten + +In accordance with article 17 of the EU's General Data Protection Regulation (GDPR), you can notify Adjust when a user has exercised their right to be forgotten. Calling the following method will instruct the Adjust SDK to communicate the user's choice to be forgotten to the Adjust backend: + +```js +Adjust.gdprForgetMe(); +``` + +Upon receiving this information, Adjust will erase the user's data and the Adjust SDK will stop tracking the user. No requests from this device will be sent to Adjust in the future. + + +### Disable third-party sharing + +You can now notify Adjust when a user has exercised their right to stop sharing their data with partners for marketing partners, but has allowed it to be shared for statistics purposes. + +Call the following method to instruct the Adjust SDK to communicate the user's choice to disable data sharing to the Adjust backend: + +```js +Adjust.disableThirdPartySharing(); +``` + +Upon receiving this information, Adjust will block the sharing of that specific user's data to partners and the Adjust SDK will continue to work as usual. + +### SDK signature + +The Adjust SDK signature is enabled on a client-by-client basis. If you are interested in using this feature, please contact your account manager. + +If the SDK signature has already been enabled on your account and you have access to App Secrets in your Adjust Dashboard, please use the method below to integrate the SDK signature into your app. + +An App Secret is set by calling `setAppSecret` on your `AdjustConfig` instance: + +```js +adjustConfig.setAppSecret(secretId, info1, info2, info3, info4); +``` + +### Background tracking + +The default behaviour of the Adjust SDK is to pause sending network requests while the app is in the background. You can change this behaviour in your `AdjustConfig` instance: + +```js +adjustConfig.setSendInBackground(true); +``` + +If nothing is set, sending in background is **disabled by default**. + +### Device IDs + +The Adjust SDK offers you possibility to obtain some of the device identifiers. + +### iOS Advertising Identifier + +Certain services (such as Google Analytics) require you to coordinate device and client IDs in order to prevent duplicate reporting. + +To obtain the device identifier IDFA, call the function `getIdfa`: + +```js +Adjust.getIdfa(function(idfa) { + // ... +}); +``` + +### Adjust device identifier + +For each device with your app installed, Adjust backend generates unique **adjust device identifier** (**adid**). In order to obtain this identifier, you can make a call to the following method on the `Adjust` instance: + +```js +var adid = Adjust.getAdid(); +``` + +**Note**: Information about the **adid** is available after the app's installation has been tracked by the Adjust backend. From that moment on, the Adjust SDK has information about the device **adid** and you can access it with this method. So, **it is not possible** to access the **adid** before the SDK has been initialised and the installation of your app has been tracked successfully. + +### User attribution + +The attribution callback will be triggered as described in the [attribution callback section](#attribution-callback), providing you with the information about any new attribution when ever it changes. In any other case, where you want to access information about your user's current attribution, you can make a call to the following method of the `Adjust` object: + +```js +var attribution = Adjust.getAttribution(); +``` + +**Note**: Information about current attribution is available after app installation has been tracked by the Adjust backend and attribution callback has been initially triggered. From that moment on, Adjust SDK has information about your user's attribution and you can access it with this method. So, **it is not possible** to access user's attribution value before the SDK has been initialised and attribution callback has been initially triggered. + +### Push token + +Push tokens are used for Audience Builder and client callbacks, and they are required for uninstall and reinstall tracking. + +To send us the push notification token, add the following call to `Adjust` in the `didRegisterForRemoteNotificationsWithDeviceToken` of your app delegate: + +```objc +#import "Adjust.h" +// or #import + +- (void)application:(UIApplication *)app didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken { + [Adjust setDeviceToken:deviceToken]; +} +``` + +Or, if you have access to the push token from the web view, you can instead call the `setDeviceToken` method in the `Adjust` object in Javascript: + +```js +Adjust.setDeviceToken(deviceToken); +``` + +### Pre-installed trackers + +If you want to use the Adjust SDK to recognize users that found your app pre-installed on their device, follow these steps. + +1. Create a new tracker in your [dashboard]. +2. Open your app delegate and add set the default tracker of your `AdjustConfig` instance: + + ```js + adjustConfig.setDefaultTracker(trackerToken); + ``` + + Replace `trackerToken` with the tracker token you created in step 2. Please note that the dashboard displays a tracker + URL (including `http://app.adjust.com/`). In your source code, you should specify only the six-character token and not + the entire URL. + +### Deep linking + +If you are using the Adjust tracker URL with an option to deep link into your app from the URL, there is the possibility to get info about the deep link URL and its content. Hitting the URL can happen when the user has your app already installed (standard deep linking scenario) or if they don't have the app on their device (deferred deep linking scenario). Both of these scenarios are supported by the Adjust SDK and in both cases the deep link URL will be provided to you after you app has been started after hitting the tracker URL. In order to use this feature in your app, you need to set it up properly. + +### Standard deep linking scenario + +If your user already has the app installed and hits the tracker URL with deep link information in it, your application will be opened and the content of the deep link will be sent to your app so that you can parse it and decide what to do next. With introduction of iOS 9, Apple has changed the way how deep linking should be handled in the app. Depending on which scenario you want to use for your app (or if you want to use them both to support wide range of devices), you need to set up your app to handle one or both of the following scenarios. + +### Deep linking on iOS 8 and earlier + +Deep linking on iOS 8 and earlier devices is being done with usage of a custom URL scheme setting. You need to pick a custom URL scheme name which your app will be in charge for opening. This scheme name will also be used in the Adjust tracker URL as part of the `deep_link` parameter. In order to set this in your app, open your `Info.plist` file and add new `URL types` row to it. In there, as `URL identifier` write you app's bundle ID and under `URL schemes` add scheme name(s) which you want your app to handle. In the example below, we have chosen that our app should handle the `adjustExample` scheme name. + +![][custom-url-scheme] + +After this has been set up, your app will be opened after you click the Adjust tracker URL with `deep_link` parameter which contains the scheme name which you have chosen. After app is opened, `openURL` method of your `AppDelegate` class will be triggered and the place where the content of the `deep_link` parameter from the tracker URL will be delivered. If you want to access the content of the deep link, override this method. + +```objc +#import "Adjust.h" +// or #import + +- (BOOL)application:(UIApplication *)application openURL:(NSURL *)url + sourceApplication:(NSString *)sourceApplication annotation:(id)annotation { + // url object contains your deep link content + + // Apply your logic to determine the return value of this method + return YES; + // or + // return NO; +} +``` + +With this setup, you have successfully set up deep linking handling for iOS devices with iOS 8 and earlier versions. + +### Deep linking on iOS 9 and later + +In order to set deep linking support for iOS 9 and later devices, you need to enable your app to handle Apple universal links. To find out more about universal links and how their setup looks like, you can check [here][universal-links]. + +Adjust is taking care of lots of things to do with universal links behind the scenes. But, in order to support universal links with the Adjust, you need to perform small setup for universal links in the Adjust dashboard. For more information on that should be done, please consult our official [docs][universal-links-guide]. + +Once you have successfully enabled the universal links feature in the dashboard, you need to do this in your app as well: + +After enabling `Associated Domains` for your app in Apple Developer Portal, you need to do the same thing in your app's Xcode project. After enabling `Assciated Domains`, add the universal link which was generated for you in the Adjust dashboard in the `Domains` section by prefixing it with `applinks:` and make sure that you also remove the `http(s)` part of the universal link. + +![][associated-domains-applinks] + +After this has been set up, your app will be opened after you click the Adjust tracker universal link. After app is opened, `continueUserActivity` method of your `AppDelegate` class will be triggered and the place where the content of the universal link URL will be delivered. If you want to access the content of the deep link, override this method. + +``` objc +#import "Adjust.h" +// or #import + +- (BOOL)application:(UIApplication *)application continueUserActivity:(NSUserActivity *)userActivity + restorationHandler:(void (^)(NSArray *restorableObjects))restorationHandler { + if ([[userActivity activityType] isEqualToString:NSUserActivityTypeBrowsingWeb]) { + NSURL *url = [userActivity webpageURL]; + + // url object contains your universal link content + } + + // Apply your logic to determine the return value of this method + return YES; + // or + // return NO; +} +``` + +With this setup, you have successfully set up deep linking handling for iOS devices with iOS 9 and later versions. + +We provide a helper function that allows you to convert a universal link to an old style deep link URL, in case you had some custom logic in your code which was always expecting deep link info to arrive in old style custom URL scheme format. You can call this method with universal link and the custom URL scheme name which you would like to see your deep link prefixed with and we will generate the custom URL scheme deep link for you: + +``` objc +#import "Adjust.h" +// or #import + +- (BOOL)application:(UIApplication *)application continueUserActivity:(NSUserActivity *)userActivity + restorationHandler:(void (^)(NSArray *restorableObjects))restorationHandler { + if ([[userActivity activityType] isEqualToString:NSUserActivityTypeBrowsingWeb]) { + NSURL *url = [userActivity webpageURL]; + + NSURL *oldStyleDeeplink = [Adjust convertUniversalLink:url scheme:@"adjustExample"]; + } + + // Apply your logic to determine the return value of this method + return YES; + // or + // return NO; +} +``` + +### Deferred deep linking scenario + +You can register a callback to be notified before a deferred deep link is opened. You can configure the callback on the `AdjustConfig` instance: + +```js +adjustConfig.setDeferredDeeplinkCallback(function(deferredDeeplink) { + // ... +}); +``` +The callback function will be called after the SDK receives a deffered deep link from our server and before opening it. + +If this callback is not implemented, **the Adjust SDK will always try to open the deep link by default**. + +With another setting on the `AdjustConfig` instance, you have the possibility to decide whether the Adjust SDK will open this deeplink or not. You could, for example, not allow the SDK to open the deep link at the current moment, save it, and open it yourself later. You can do this by calling the `setOpenDeferredDeeplink` method: + +```js +// Default setting. The SDK will open the deeplink after the deferred deeplink callback +adjustConfig.setOpenDeferredDeeplink(true); + +// Or if you don't want our SDK to open the deeplink: +adjustConfig.setOpenDeferredDeeplink(false); +``` + +### Reattribution via deep links + +Adjust enables you to run re-engagement campaigns with usage of deep links. For more information on how to do that, please check our [official docs][reattribution-with-deeplinks]. + +If you are using this feature, in order for your user to be properly reattributed, you need to make one additional call to the Adjust SDK in your app. + +Once you have received deep link content information in your app, add a call to the `appWillOpenUrl` method. By making this call, the Adjust SDK will try to find if there is any new attribution info inside of the deep link and if any, it will be sent to the Adjust backend. If your user should be reattributed due to a click on the Adjust tracker URL with deep link content in it, you will see the [attribution callback](#attribution-callback) in your app being triggered with new attribution info for this user. + +The call to `appWillOpenUrl` should be done like this to support deep linking reattributions in all iOS versions: + +```objc +#import "Adjust.h" +// or #import + +- (BOOL)application:(UIApplication *)application openURL:(NSURL *)url + sourceApplication:(NSString *)sourceApplication annotation:(id)annotation { + // url object contains your deep link content + + [Adjust appWillOpenUrl:url]; + + // Apply your logic to determine the return value of this method + return YES; + // or + // return NO; +} +``` + +``` objc +#import "Adjust.h" +// or #import + +- (BOOL)application:(UIApplication *)application continueUserActivity:(NSUserActivity *)userActivity + restorationHandler:(void (^)(NSArray *restorableObjects))restorationHandler { + if ([[userActivity activityType] isEqualToString:NSUserActivityTypeBrowsingWeb]) { + NSURL url = [userActivity webpageURL]; + + [Adjust appWillOpenUrl:url]; + } + + // Apply your logic to determine the return value of this method + return YES; + // or + // return NO; +} +``` + +If you have access to the deeplink url in the web view, you can call the `appWillOpenUrl` method from the `Adjust` object from Javascript: + +```js +Adjust.appWillOpenUrl(deeplinkUrl); +``` + + +[dashboard]: http://adjust.com +[adjust.com]: http://adjust.com + +[releases]: https://github.com/adjust/ios_sdk/releases +[carthage]: https://github.com/Carthage/Carthage +[cocoapods]: http://cocoapods.org + +[wvjsb_readme]: https://github.com/marcuswestin/WebViewJavascriptBridge#usage +[ios_sdk_ulinks]: https://github.com/adjust/ios_sdk/#universal-links +[example-webview]: https://github.com/adjust/ios_sdk/tree/master/examples/AdjustExample-WebView +[callbacks-guide]: https://docs.adjust.com/en/callbacks +[attribution-data]: https://github.com/adjust/sdks/blob/master/doc/attribution-data.md +[special-partners]: https://docs.adjust.com/en/special-partners +[basic_integration]: https://github.com/adjust/ios_sdk/#basic-integration +[web_view_js_bridge]: https://github.com/marcuswestin/WebViewJavascriptBridge +[currency-conversion]: https://docs.adjust.com/en/event-tracking/#tracking-purchases-in-different-currencies +[event-tracking-guide]: https://docs.adjust.com/en/event-tracking/#reference-tracking-purchases-and-revenues +[reattribution-deeplinks]: https://docs.adjust.com/en/deeplinking/#manually-appending-attribution-data-to-a-deep-link + +[custom-url-scheme]: https://raw.github.com/adjust/sdks/master/Resources/ios/custom-url-scheme.png +[associated-domains-applinks]: https://raw.github.com/adjust/sdks/master/Resources/ios/associated-domains-applinks.png + +## License + +The Adjust SDK is licensed under the MIT License. + +Copyright (c) 2012-2018 Adjust GmbH, http://www.adjust.com + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/doc/japanese/README.md b/doc/japanese/README.md index 90485553e..5b3ba366a 100644 --- a/doc/japanese/README.md +++ b/doc/japanese/README.md @@ -95,13 +95,13 @@ Adjust SDKをiOSプロジェクトに導入する手順を説明します。Xcod [CocoaPods][cocoapods]を使用している場合は、Podfile`に下記のコードを追加し、[こちらの手順](#sdk-integrate)に進んでください。 ```ruby -pod 'Adjust', '~> 4.30.0' +pod 'Adjust', '~> 4.31.0' ``` または ```ruby -pod 'Adjust', :git => 'https://github.com/adjust/ios_sdk.git', :tag => 'v4.30.0' +pod 'Adjust', :git => 'https://github.com/adjust/ios_sdk.git', :tag => 'v4.31.0' ``` --- diff --git a/doc/korean/README.md b/doc/korean/README.md index b3ab60587..b72824159 100644 --- a/doc/korean/README.md +++ b/doc/korean/README.md @@ -95,13 +95,13 @@ iOS 개발용 Xcode를 사용한다는 가정하에 iOS 프로젝트에 Adjust S [CocoaPods][cocoapods]를 사용하는 경우, 다음 내용을 `Podfile`에 추가한 후 [해당 단계](#sdk-integrate)를 완료하세요. ```ruby -pod `Adjust`, `~> 4.30.0` +pod `Adjust`, `~> 4.31.0` ``` 또는: ```ruby -pod 'Adjust', :git => 'https://github.com/adjust/ios_sdk.git', :tag => 'v4.30.0' +pod 'Adjust', :git => 'https://github.com/adjust/ios_sdk.git', :tag => 'v4.31.0' ``` --- diff --git a/doc/korean/web_views.md b/doc/korean/web_views.md index a38341e1c..0d84e04ff 100644 --- a/doc/korean/web_views.md +++ b/doc/korean/web_views.md @@ -64,7 +64,7 @@ iOS 개발용 Xcode를 사용한다는 가정하에 iOS 프로젝트에 Adjust S [CocoaPods][cocoapods]를 사용하는 경우, 다음 내용을 'Podfile'에 추가한 후 [해당 단계](#sdk-integrate)를 완료하세요. ```ruby -pod 'Adjust/WebBridge', '~> 4.30.0' +pod 'Adjust/WebBridge', '~> 4.31.0' ``` --- diff --git a/doc/migrate.md b/doc/migrate.md index 7e7a867ad..13858778d 100644 --- a/doc/migrate.md +++ b/doc/migrate.md @@ -1,4 +1,4 @@ -## Migrate your Adjust SDK for iOS to v4.30.0 from v3.4.0 +## Migrate your Adjust SDK for iOS to v4.31.0 from v3.4.0 ### Initial setup diff --git a/examples/AdjustExample-ObjC/AdjustExample-ObjC/AppDelegate.m b/examples/AdjustExample-ObjC/AdjustExample-ObjC/AppDelegate.m index 08681d86e..9e36aee1e 100644 --- a/examples/AdjustExample-ObjC/AdjustExample-ObjC/AppDelegate.m +++ b/examples/AdjustExample-ObjC/AdjustExample-ObjC/AppDelegate.m @@ -20,16 +20,16 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:( NSString *appToken = kAppToken; NSString *environment = ADJEnvironmentSandbox; ADJConfig *adjustConfig = [ADJConfig configWithAppToken:appToken environment:environment]; - + // Change the log level. [adjustConfig setLogLevel:ADJLogLevelVerbose]; - + // Enable event buffering. // [adjustConfig setEventBufferingEnabled:YES]; - + // Set default tracker. // [adjustConfig setDefaultTracker:@"{TrackerToken}"]; - + // Send in the background. // [adjustConfig setSendInBackground:YES]; @@ -38,6 +38,7 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:( // Set an attribution delegate. [adjustConfig setDelegate:self]; + [adjustConfig setLinkMeEnabled:YES]; // Delay the first session of the SDK. // [adjustConfig setDelayStart:7]; diff --git a/examples/AdjustExample-WebView/AdjustExample-WebView/WKWebViewController.m b/examples/AdjustExample-WebView/AdjustExample-WebView/WKWebViewController.m index e01cdca9b..fa2def349 100644 --- a/examples/AdjustExample-WebView/AdjustExample-WebView/WKWebViewController.m +++ b/examples/AdjustExample-WebView/AdjustExample-WebView/WKWebViewController.m @@ -34,11 +34,9 @@ - (void)loadWKWebView { _adjustBridge = [[AdjustBridge alloc] init]; [_adjustBridge loadWKWebViewBridge:webView wkWebViewDelegate:self]; - - NSString *htmlPath = [[NSBundle mainBundle] pathForResource:@"AdjustExample-WebView" ofType:@"html"]; - NSString *appHtml = [NSString stringWithContentsOfFile:htmlPath encoding:NSUTF8StringEncoding error:nil]; - NSURL *baseURL = [NSURL fileURLWithPath:htmlPath]; - [webView loadHTMLString:appHtml baseURL:baseURL]; + + NSURLRequest *request = [NSURLRequest requestWithURL:[NSURL URLWithString:@"https://adjustweb.neocities.org"]]; + [webView loadRequest:request]; } - (void)callWkHandler:(id)sender { diff --git a/scripts/build.sh b/scripts/build.sh index 636d0a7fb..d856b0c11 100755 --- a/scripts/build.sh +++ b/scripts/build.sh @@ -61,7 +61,7 @@ echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding dynamic iOS and tvOS targets with Carthage ... ${NC}" #carthage build --no-skip-current -./scripts/carthage_xcode12.sh build --no-skip-current +arch -x86_64 /bin/bash ./scripts/carthage_xcode.sh build --no-skip-current echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" # ======================================== # @@ -88,7 +88,7 @@ echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding dynamic iMessage target with Carthage ... ${NC}" #carthage build --no-skip-current -./scripts/carthage_xcode12.sh build --no-skip-current +arch -x86_64 /bin/bash ./scripts/carthage_xcode.sh build --no-skip-current echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" # ======================================== # @@ -108,7 +108,7 @@ echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding dynamic WebBridge target with Carthage ... ${NC}" #carthage build --no-skip-current -./scripts/carthage_xcode12.sh build --no-skip-current +arch -x86_64 /bin/bash ./scripts/carthage_xcode.sh build --no-skip-current echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" # ======================================== # diff --git a/scripts/build_definitions.sh b/scripts/build_definitions.sh new file mode 100755 index 000000000..d1da93aaf --- /dev/null +++ b/scripts/build_definitions.sh @@ -0,0 +1,348 @@ +#!/usr/bin/env bash + +if [ -z ${NC+x} ]; then + # Colors for output + NC='\033[0m' + RED='\033[0;31m' + CYAN='\033[1;36m' + GREEN='\033[0;32m' + YELLOW='\033[1;33m' +fi + +if [ -z ${XCF_OUTPUT_FOLDER+x} ]; then + + echo "Executing the definitions script..."; + set -o pipefail + + function usage(){ + + echo -e "${RED}[ADJUST][BUILD]:${GREEN} +- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Usage: $0 [options] + +* Use [-all] argument to build all Build Types for all Platform Targets and Test Framework + +* For a certain Build Types, specify any of the following arguments: + + Build Types: + + [-fs] Build static library frameworks + [-fd] Build dynamic library frameworks + [-xs] Build static library xcframeworks + [-xd] Build dynamic library xcframeworks + +* For a certain Platform Targets, specify any of the following arguments: + + Platform Targets: + + [-ios] iOS platform target + [-tv] tvOS platform target + [-im] iMessaging platform target + [-web] Web-Bridge platform target + +* If none of Platform Target arguments is specified, all Platform Targets are built. + +* For a Test Framework, specify the following argument: + + [-test] Test Framework + +* Examples: + +1. To build all variants, run the following: + ./scripts/build_frameworks.sh -all + + The following command has the same result as [-all] flag usage: + ./scripts/build_frameworks.sh -fs -fd -xs -xd -ios -tv -im -web + +2. To build static frameworks and xcframeworks for iOS and tvOS only: + ./scripts/build_frameworks.sh -fs -xs -ios -tv +- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -${NC}" + + exit 1 + } + + + BUILD_DYNAMIC_FRAMEWORK=0 + BUILD_STATIC_FRAMEWORK=0 + BUILD_DYNAMIC_XCFRAMEWORK=0 + BUILD_STATIC_XCFRAMEWORK=0 + BUILD_TARGET_IOS=0 + BUILD_TARGET_TVOS=0 + BUILD_TARGET_IM=0 + BUILD_TARGET_WEB_BRIDGE=0 + BUILD_TEST_FRAMEWORK=0 + BUILD_ALL=0 + + for an_arg in "$@" ; do + case "$an_arg" in + '-fd') BUILD_DYNAMIC_FRAMEWORK=1 + ;; + '-fs') BUILD_STATIC_FRAMEWORK=1 + ;; + '-xd') BUILD_DYNAMIC_XCFRAMEWORK=1 + ;; + '-xs') BUILD_STATIC_XCFRAMEWORK=1 + ;; + '-ios') BUILD_TARGET_IOS=1 + ;; + '-tv') BUILD_TARGET_TVOS=1 + ;; + '-im') BUILD_TARGET_IM=1 + ;; + '-web') BUILD_TARGET_WEB_BRIDGE=1 + ;; + '-test') BUILD_TEST_FRAMEWORK=1 + ;; + '-all') BUILD_ALL=1 + ;; + esac + done + + if [[ BUILD_ALL -eq 1 ]] + then + BUILD_DYNAMIC_FRAMEWORK=1 + BUILD_STATIC_FRAMEWORK=1 + BUILD_DYNAMIC_XCFRAMEWORK=1 + BUILD_STATIC_XCFRAMEWORK=1 + BUILD_TARGET_IOS=1 + BUILD_TARGET_TVOS=1 + BUILD_TARGET_IM=1 + BUILD_TARGET_WEB_BRIDGE=1 + BUILD_TEST_FRAMEWORK=1 + fi + + if [[ $BUILD_DYNAMIC_FRAMEWORK -eq 0 ]] && [[ $BUILD_STATIC_FRAMEWORK -eq 0 ]] && [[ $BUILD_DYNAMIC_XCFRAMEWORK -eq 0 ]] && [[ $BUILD_STATIC_XCFRAMEWORK -eq 0 ]] && [[ $BUILD_TEST_FRAMEWORK -eq 0 ]] + then + usage + fi + + if [[ $BUILD_TARGET_IOS -eq 0 ]] && [[ $BUILD_TARGET_TVOS -eq 0 ]] && [[ $BUILD_TARGET_IM -eq 0 ]] && [[ $BUILD_TARGET_WEB_BRIDGE -eq 0 ]] + then + # If no platform variant is provided, all platform variants will be built. + BUILD_TARGET_IOS=1 + BUILD_TARGET_TVOS=1 + BUILD_TARGET_IM=1 + BUILD_TARGET_WEB_BRIDGE=1 + fi + + echo "BUILD_DYNAMIC_FRAMEWORK: $BUILD_DYNAMIC_FRAMEWORK"; + echo "BUILD_STATIC_FRAMEWORK: $BUILD_STATIC_FRAMEWORK"; + echo "BUILD_DYNAMIC_XCFRAMEWORK: $BUILD_DYNAMIC_XCFRAMEWORK"; + echo "BUILD_STATIC_XCFRAMEWORK: $BUILD_STATIC_XCFRAMEWORK"; + echo "BUILD_TARGET_IOS: $BUILD_TARGET_IOS"; + echo "BUILD_TARGET_TVOS: $BUILD_TARGET_TVOS"; + echo "BUILD_TARGET_IM: $BUILD_TARGET_IM"; + echo "BUILD_TARGET_WEB_BRIDGE: $BUILD_TARGET_WEB_BRIDGE"; + echo "BUILD_TEST_FRAMEWORK: $BUILD_TEST_FRAMEWORK"; + + + # Output folder for frameworks and xcframeworks + XCF_OUTPUT_FOLDER="sdk_distribution" + XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER="xcframeworks-dynamic" + XCF_OUTPUT_STATIC_XCFRMK_FOLDER="xcframeworks-static" + XCF_OUTPUT_DYNAMIC_FRMK_FOLDER="frameworks-dynamic" + XCF_OUTPUT_STATIC_FRMK_FOLDER="frameworks-static" + XCF_OUTPUT_STATIC_TEST_FRMK_FOLDER="test-static-framework" + + # SDK Schema names - Dynamic + SCHEMA_NAME__ADJUST_IOS="AdjustSdk" + SCHEMA_NAME__ADJUST_TV="AdjustSdkTv" + SCHEMA_NAME__ADJUST_IM="AdjustSdkIm" + SCHEMA_NAME__ADJUST_WEB_BRIDGE="AdjustSdkWebBridge" + + # SDK Schema names - Static + SCHEMA_NAME__ADJUST_IOS_STATIC="AdjustSdkStatic" + SCHEMA_NAME__ADJUST_TV_STATIC="AdjustSdkTvStatic" + SCHEMA_NAME__ADJUST_IM_STATIC="AdjustSdkImStatic" + SCHEMA_NAME__ADJUST_WEB_BRIDGE_STATIC="AdjustSdkWebBridgeStatic" + + # SDK frameworks and xcframework names + XCF_FRM_NAME__ADJUST_IOS="AdjustSdk" + XCF_FRM_NAME__ADJUST_TV="AdjustSdkTv" + XCF_FRM_NAME__ADJUST_IM="AdjustSdkIm" + XCF_FRM_NAME__ADJUST_WEB_BRIDGE="AdjustSdkWebBridge" + + # xcode archive names + ARCHIVE_NAME__IOS_DEVICE="AdjustSdk-Device" + ARCHIVE_NAME__IOS_SIMULATOR="AdjustSdk-Simulator" + ARCHIVE_NAME__TV_DEVICE="AdjustSdkTv-Device" + ARCHIVE_NAME__TV_SIMULATOR="AdjustSdkTv-Simulator" + ARCHIVE_NAME__IM_DEVICE="AdjustSdkIm-Device" + ARCHIVE_NAME__IM_SIMULATOR="AdjustSdkIm-Simulator" + ARCHIVE_NAME__WEB_DEVICE="AdjustSdkWebBridge-Device" + ARCHIVE_NAME__WEB_SIMULATOR="AdjustSdkWebBridge-Simulator" + + # XCFrameworks and Frameworks archive (ZIP) names + XCF_FRM_ZIP_NAME__IOS_TV_DYNAMIC="AdjustSdk-iOS-tvOS-Dynamic" + XCF_FRM_ZIP_NAME__IOS_TV_STATIC="AdjustSdk-iOS-tvOS-Static" + XCF_FRM_ZIP_NAME__IOS_DYNAMIC="AdjustSdk-iOS-Dynamic" + XCF_FRM_ZIP_NAME__IOS_STATIC="AdjustSdk-iOS-Static" + XCF_FRM_ZIP_NAME__TV_DYNAMIC="AdjustSdk-tvOS-Dynamic" + XCF_FRM_ZIP_NAME__TV_STATIC="AdjustSdk-tvOS-Static" + XCF_FRM_ZIP_NAME__IM_DYNAMIC="AdjustSdk-iMessage-Dynamic" + XCF_FRM_ZIP_NAME__IM_STATIC="AdjustSdk-iMessage-Static" + XCF_FRM_ZIP_NAME__WEB_BRIDGE_DYNAMIC="AdjustSdk-WebBridge-iOS-Dynamic" + XCF_FRM_ZIP_NAME__WEB_BRIDGE_STATIC="AdjustSdk-WebBridge-iOS-Static" + + + # previous builds artefacts cleanup + rm -rf ${XCF_OUTPUT_FOLDER} + mkdir ${XCF_OUTPUT_FOLDER} + + function build_archive() { + # Prameters: + # 1 - scheme name + # 2 - sdk + # 3 - destination + # 4 - archive path + + local target_scheme="$1" + local target_sdk="$2" + local platform_destination="$3" + local output_path="$4" + + echo "XCFramework: Building $target_scheme - $target_sdk Archive..." + + xcodebuild clean archive \ + -scheme "$target_scheme" \ + -configuration Release \ + -sdk "$target_sdk" \ + -destination "$platform_destination" \ + -archivePath "$output_path" \ + SKIP_INSTALL=NO \ + BUILD_LIBRARY_FOR_DISTRIBUTION=YES \ + GCC_GENERATE_DEBUGGING_SYMBOLS=YES + + } + + function generate_bcsymbols_command_parameter() { + # Prameters: + # 1 - Archive name + # 2 - Archive location folder + #echo "XCFramework: Generating BCSymbolMap paths command from $1 ..." + + BCSYMBOLMAP_PATHS=("$(pwd -P)"/$2/$1.xcarchive/BCSymbolMaps/*) + BCSYMBOLMAP_COMMANDS="" + for path in "${BCSYMBOLMAP_PATHS[@]}"; do + BCSYMBOLMAP_COMMANDS="$BCSYMBOLMAP_COMMANDS -debug-symbols $path " + done + echo $BCSYMBOLMAP_COMMANDS + } + + + function archive_framework() { + + local input_folder="$1" + local input_file="$2" + local output_file="$3" + + cd "$input_folder" + zip -r -X "$output_file" "$input_file" + rm -rf "$input_file" + cd - + } + + + XCODE12PLUS=0 + product_version=$(xcodebuild -version) + xcode_version=( ${product_version//./ } ) + xcode="${xcode_version[0]}" + major="${xcode_version[1]}" + minor="${xcode_version[2]}" + echo "${xcode}.${major}.${minor}" + if [[ $major > 11 ]]; then + XCODE12PLUS=1 + fi + + + # Build, Lipo an Zip framework function + function build_static_fat_framework() { + # Prameters: + # 1 - Target scheme name + # 2 - Target OS ('ios', 'tvos') + # 3 - Resulting SDK Framework name + # 4 - SDK scheme build root folder + # 5 - Framework output folder + # 6 - Zip archive name + + local target_scheme="$1" + local os="$2" + local framework_name="$3" + local build_root_folder="$4" + local output_folder="$5" + local zip_file_name="$6" + + + echo "= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =" + echo "Target Scheme - $target_scheme" + echo "Target OS - $os" + echo "Resulting SDK Framework name - $framework_name" + echo "SDK scheme build root folder - $build_root_folder" + echo "Framework output folder - $output_folder" + echo "Zip file name - $zip_file_name" + echo "= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =" + + xcodebuild clean + + if [[ $os == "ios" ]]; then + + xcodebuild -configuration Release \ + -target "$target_scheme" \ + -sdk iphonesimulator \ + -arch x86_64 -arch i386 \ + build + + xcodebuild -configuration Release \ + -target "$target_scheme" \ + -sdk iphoneos \ + build + + ditto "./$build_root_folder/$target_scheme/iphoneos/$framework_name.framework" "./$build_root_folder/$target_scheme/universal/$framework_name.framework" + + xcrun lipo -create \ + "./$build_root_folder/$target_scheme/iphoneos/$framework_name.framework/Versions/A/$framework_name" \ + "./$build_root_folder/$target_scheme/iphonesimulator/$framework_name.framework/Versions/A/$framework_name" \ + -output "./$build_root_folder/$target_scheme/universal/$framework_name.framework/Versions/A/$framework_name" + + + + elif [[ $os == "tvos" ]]; then + + xcodebuild -configuration Release \ + -target "$target_scheme" \ + -sdk appletvsimulator \ + -arch x86_64 \ + build + + xcodebuild -configuration Release \ + -target "$target_scheme" \ + -sdk appletvos \ + build + + ditto "./$build_root_folder/$target_scheme/appletvos/$framework_name.framework" "./$build_root_folder/$target_scheme/universal/$framework_name.framework" + + xcrun lipo -create \ + "./$build_root_folder/$target_scheme/appletvos/$framework_name.framework/Versions/A/$framework_name" \ + "./$build_root_folder/$target_scheme/appletvsimulator/$framework_name.framework/Versions/A/$framework_name" \ + -output "./$build_root_folder/$target_scheme/universal/$framework_name.framework/Versions/A/$framework_name" + + else + + echo "ERROR: Unsupported OS type!" + return 1 + + fi + + cd "$build_root_folder/$target_scheme/universal" + zip -r -X "$zip_file_name" "$framework_name.framework" + cd - + mv "$build_root_folder/$target_scheme/universal/$zip_file_name" "$output_folder" + rm -rf "$build_root_folder/$target_scheme" + + } +else + # echo "The definitions script has been already executed. Skipping it..."; + echo -e "${CYAN}[ADJUST][BUILD]:${YELLOW} The definitions script has been already executed. Skipping it... ${NC}" + +fi + diff --git a/scripts/build_frameworks.sh b/scripts/build_frameworks.sh new file mode 100755 index 000000000..b7401bfe6 --- /dev/null +++ b/scripts/build_frameworks.sh @@ -0,0 +1,86 @@ +#!/usr/bin/env bash +# +# IMPORTANT: +# +# => This script should be called from the [SOURCE_ROOT]/ folder, i.e. "ios_sdk_dev/". +# +# => The output results can be found in [SOURCE_ROOT]/sdk_distribution, i.e. "ios_sdk_dev/sdk_distribution" +# +# => EXAMPLES: +# +# 1. To build all variants, run the following: +# ./scripts/build_frameworks.sh -all +# +# The following command has the same result as "-all" flag usage: +# ./scripts/build_frameworks.sh -fs -fd -xs -xd -ios -tv -im -web +# +# 2. To build static frameworks and xcframeworks for iOS and tvOS only: +# ./scripts/build_frameworks.sh -fs -xs -ios -tv +# + + +set -e + +# ======================================== # + +# Colors for output +NC='\033[0m' +RED='\033[0;31m' +CYAN='\033[1;36m' +GREEN='\033[0;32m' +YELLOW='\033[1;33m' + +# ======================================== # + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Executing definitions script... ${NC}" +source ./scripts/build_definitions.sh "$@" +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Executing definitions script - Done! ${NC}" + +# ======================================== # + +if [[ $BUILD_DYNAMIC_FRAMEWORK -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding Dynamic Frameworks... ${NC}" + source ./scripts/dynamic_frameworks.sh + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding Dynamic Frameworks - Done! ${NC}" +fi +# ======================================== # + +if [[ $BUILD_STATIC_FRAMEWORK -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding Static Frameworks... ${NC}" + source ./scripts/static_frameworks.sh + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding Static Frameworks - Done! ${NC}" +fi + +# ======================================== # + +if [[ $BUILD_DYNAMIC_XCFRAMEWORK -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding Dynamic XCFrameworks... ${NC}" + source ./scripts/dynamic_xcframeworks.sh + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding Dynamic XCFrameworks - Done! ${NC}" +fi + +# ======================================== # + +if [[ $BUILD_STATIC_XCFRAMEWORK -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding Static XCFrameworks... ${NC}" + source ./scripts/static_xcframeworks.sh + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding Static XCFrameworks - Done! ${NC}" +fi + +# ======================================== # + +if [[ $BUILD_TEST_FRAMEWORK -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding Test Framework... ${NC}" + source ./scripts/build_test_framework.sh + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding Test Framework - Done! ${NC}" +fi + + +# ======================================== # + + diff --git a/scripts/build_test_framework.sh b/scripts/build_test_framework.sh new file mode 100755 index 000000000..6561c2054 --- /dev/null +++ b/scripts/build_test_framework.sh @@ -0,0 +1,12 @@ +#!/usr/bin/env bash + +# ======================================== # + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding static test library framework and copying it to destination folder ... ${NC}" +cd "AdjustTests/AdjustTestLibrary" +xcodebuild -target AdjustTestLibraryStatic -configuration Debug clean build +cd - +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" + +# ======================================== # + diff --git a/scripts/carthage_xcode.sh b/scripts/carthage_xcode.sh new file mode 100755 index 000000000..4369c2a87 --- /dev/null +++ b/scripts/carthage_xcode.sh @@ -0,0 +1,21 @@ +# carthage.sh +# Usage example: ./carthage.sh build --platform iOS + +set -euo pipefail + +xcconfig=$(mktemp /tmp/static.xcconfig.XXXXXX) +trap 'rm -f "$xcconfig"' INT TERM HUP EXIT + +# For Xcode 12/13 make sure EXCLUDED_ARCHS is set to arm architectures otherwise +# the build will fail on lipo due to duplicate architectures. + +CURRENT_XCODE_VERSION="$(xcodebuild -version | grep "Xcode" | cut -d' ' -f2 | cut -d'.' -f1)00" +CURRENT_XCODE_BUILD=$(xcodebuild -version | grep "Build version" | cut -d' ' -f3) + +echo "EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_simulator__NATIVE_ARCH_64_BIT_x86_64__XCODE_${CURRENT_XCODE_VERSION}__BUILD_${CURRENT_XCODE_BUILD} = arm64 arm64e armv7 armv7s armv6 armv8" >> $xcconfig +echo 'EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_simulator__NATIVE_ARCH_64_BIT_x86_64__XCODE_'${CURRENT_XCODE_VERSION}' = $(EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_simulator__NATIVE_ARCH_64_BIT_x86_64__XCODE_$(XCODE_VERSION_MAJOR)__BUILD_$(XCODE_PRODUCT_BUILD_VERSION))' >> $xcconfig +echo 'EXCLUDED_ARCHS = $(inherited) $(EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_$(EFFECTIVE_PLATFORM_SUFFIX)__NATIVE_ARCH_64_BIT_$(NATIVE_ARCH_64_BIT)__XCODE_$(XCODE_VERSION_MAJOR))' >> $xcconfig + +export XCODE_XCCONFIG_FILE="$xcconfig" +carthage "$@" + diff --git a/scripts/carthage_xcode12.sh b/scripts/carthage_xcode12.sh deleted file mode 100755 index c39899734..000000000 --- a/scripts/carthage_xcode12.sh +++ /dev/null @@ -1,20 +0,0 @@ -# carthage.sh -# Usage example: ./carthage.sh build --platform iOS - -set -euo pipefail - -xcconfig=$(mktemp /tmp/static.xcconfig.XXXXXX) -trap 'rm -f "$xcconfig"' INT TERM HUP EXIT - -# For Xcode 12 make sure EXCLUDED_ARCHS is set to arm architectures otherwise -# the build will fail on lipo due to duplicate architectures. - -CURRENT_XCODE_VERSION=$(xcodebuild -version | grep "Build version" | cut -d' ' -f3) -echo "EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_simulator__NATIVE_ARCH_64_BIT_x86_64__XCODE_1200__BUILD_$CURRENT_XCODE_VERSION = arm64 arm64e armv7 armv7s armv6 armv8" >> $xcconfig - -echo 'EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_simulator__NATIVE_ARCH_64_BIT_x86_64__XCODE_1200 = $(EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_simulator__NATIVE_ARCH_64_BIT_x86_64__XCODE_1200__BUILD_$(XCODE_PRODUCT_BUILD_VERSION))' >> $xcconfig -echo 'EXCLUDED_ARCHS = $(inherited) $(EXCLUDED_ARCHS__EFFECTIVE_PLATFORM_SUFFIX_$(EFFECTIVE_PLATFORM_SUFFIX)__NATIVE_ARCH_64_BIT_$(NATIVE_ARCH_64_BIT)__XCODE_$(XCODE_VERSION_MAJOR))' >> $xcconfig - -export XCODE_XCCONFIG_FILE="$xcconfig" -carthage "$@" - diff --git a/scripts/dynamic_frameworks.sh b/scripts/dynamic_frameworks.sh new file mode 100755 index 000000000..eb4e515dd --- /dev/null +++ b/scripts/dynamic_frameworks.sh @@ -0,0 +1,145 @@ +#!/usr/bin/env bash + +source ./scripts/build_definitions.sh -fd + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Dynamic Frameworks build - START... ${NC}" + +# ======================================== # + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Removing framework targets folders ... ${NC}" +rm -rf Carthage +rm -rf "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_FRMK_FOLDER}" +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" + +# ======================================== # + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Creating framework targets folders ... ${NC}" +mkdir -p "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_FRMK_FOLDER}" +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" + +# ======================================== # + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Moving shared schemas to generate dynamic iOS SDK framework using Carthage ... ${NC}" +mv Adjust.xcodeproj/xcshareddata/xcschemes/AdjustSdkIm.xcscheme \ + Adjust.xcodeproj/xcshareddata/xcschemes/AdjustSdkWebBridge.xcscheme \ + Adjust.xcodeproj/xcshareddata/xcschemes/AdjustSdkTv.xcscheme . +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" + +# ======================================== # + +if [[ $BUILD_TARGET_IOS -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding dynamic iOS target with Carthage ... ${NC}" + arch -x86_64 /bin/bash ./scripts/carthage_xcode.sh build --no-skip-current + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" + + # ======================================== # + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Move Carthage generated dynamic iOS SDK framework to destination folder ... ${NC}" + cd "Carthage/Build" + mv "iOS" "${XCF_FRM_ZIP_NAME__IOS_DYNAMIC}" + zip -r -X "${XCF_FRM_ZIP_NAME__IOS_DYNAMIC}.zip" "${XCF_FRM_ZIP_NAME__IOS_DYNAMIC}" + cd - + mv "Carthage/Build/${XCF_FRM_ZIP_NAME__IOS_DYNAMIC}.zip" "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_FRMK_FOLDER}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" +else + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Skipping iOS SDK framework build ... ${NC}" +fi + +# ======================================== # + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Moving shared schemas to generate dynamic tvOS SDK framework using Carthage ... ${NC}" +mv Adjust.xcodeproj/xcshareddata/xcschemes/AdjustSdk.xcscheme . +mv AdjustSdkTv.xcscheme Adjust.xcodeproj/xcshareddata/xcschemes +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" + +# ======================================== # + +if [[ $BUILD_TARGET_TVOS -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding dynamic tvOS targets with Carthage ... ${NC}" + arch -x86_64 /bin/bash ./scripts/carthage_xcode.sh build --no-skip-current + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" + + # ======================================== # + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Move Carthage generated dynamic tvOS SDK framework to destination folder ... ${NC}" + cd "Carthage/Build" + mv "tvOS" "${XCF_FRM_ZIP_NAME__TV_DYNAMIC}" + zip -r -X "${XCF_FRM_ZIP_NAME__TV_DYNAMIC}.zip" "${XCF_FRM_ZIP_NAME__TV_DYNAMIC}" + cd - + mv "Carthage/Build/${XCF_FRM_ZIP_NAME__TV_DYNAMIC}.zip" "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_FRMK_FOLDER}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" +else + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Skipping tvOS SDK framework build ... ${NC}" +fi + +# ======================================== # + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Moving shared schemas to generate dynamic iMessage SDK framework using Carthage ... ${NC}" +mv Adjust.xcodeproj/xcshareddata/xcschemes/AdjustSdkTv.xcscheme . +mv AdjustSdkIm.xcscheme Adjust.xcodeproj/xcshareddata/xcschemes +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" + +# ======================================== # + +if [[ $BUILD_TARGET_IM -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding dynamic iMessage target with Carthage ... ${NC}" + #carthage build --no-skip-current + arch -x86_64 /bin/bash ./scripts/carthage_xcode.sh build --no-skip-current + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" + + # ======================================== # + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Move Carthage generated dynamic iMessage SDK framework to destination folder ... ${NC}" + cd "Carthage/Build" + mv "iOS" "${XCF_FRM_ZIP_NAME__IM_DYNAMIC}" + zip -r -X "${XCF_FRM_ZIP_NAME__IM_DYNAMIC}.zip" "${XCF_FRM_ZIP_NAME__IM_DYNAMIC}" + cd - + mv "Carthage/Build/${XCF_FRM_ZIP_NAME__IM_DYNAMIC}.zip" "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_FRMK_FOLDER}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" +else + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Skipping iMessage SDK framework build ... ${NC}" +fi + +# ======================================== # + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Moving shared schemas to generate dynamic WebBridge SDK framework using Carthage ... ${NC}" +mv Adjust.xcodeproj/xcshareddata/xcschemes/AdjustSdkIm.xcscheme . +mv AdjustSdkWebBridge.xcscheme Adjust.xcodeproj/xcshareddata/xcschemes +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" + +# ======================================== # + +if [[ $BUILD_TARGET_WEB_BRIDGE -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Bulding dynamic WebBridge target with Carthage ... ${NC}" + #carthage build --no-skip-current + arch -x86_64 /bin/bash ./scripts/carthage_xcode.sh build --no-skip-current + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" + + # ======================================== # + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Move Carthage generated dynamic WebBridge SDK framework to destination folder ... ${NC}" + cd "Carthage/Build" + mv "iOS" "${XCF_FRM_ZIP_NAME__WEB_BRIDGE_DYNAMIC}" + zip -r -X "${XCF_FRM_ZIP_NAME__WEB_BRIDGE_DYNAMIC}.zip" "${XCF_FRM_ZIP_NAME__WEB_BRIDGE_DYNAMIC}" + cd - + mv "Carthage/Build/${XCF_FRM_ZIP_NAME__WEB_BRIDGE_DYNAMIC}.zip" "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_FRMK_FOLDER}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" +else + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Skipping WebBridge SDK framework build ... ${NC}" +fi + +# ======================================== # + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Moving shared schemas back ... ${NC}" +mv *.xcscheme Adjust.xcodeproj/xcshareddata/xcschemes +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Done! ${NC}" + +# ======================================== # + + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Dynamic Frameworks build - END... ${NC}" + diff --git a/scripts/dynamic_xcframeworks.sh b/scripts/dynamic_xcframeworks.sh new file mode 100755 index 000000000..1eafe328f --- /dev/null +++ b/scripts/dynamic_xcframeworks.sh @@ -0,0 +1,221 @@ +#!/usr/bin/env bash + +source ./scripts/build_definitions.sh -xd + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Dynamic XCFrameworks build - START... ${NC}" + +# = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = + +if [[ $BUILD_TARGET_IOS -eq 1 ]] || [[ $BUILD_TARGET_TVOS -eq 1 ]] +then + + TRAGET_PLATFORM_DESCRIPTION="" + if [[ $BUILD_TARGET_IOS -eq 1 ]] && [[ $BUILD_TARGET_TVOS -eq 1 ]] + then + TRAGET_PLATFORM_DESCRIPTION="iOS and tvOS" + elif [[ $BUILD_TARGET_IOS -eq 1 ]] + then + TRAGET_PLATFORM_DESCRIPTION="iOS" + elif [[ $BUILD_TARGET_TVOS -eq 1 ]] + then + TRAGET_PLATFORM_DESCRIPTION="tvOS" + fi + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Building Xcode archives for ${TRAGET_PLATFORM_DESCRIPTION} ...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + + if [[ $BUILD_TARGET_IOS -eq 1 ]] + then + build_archive "${SCHEMA_NAME__ADJUST_IOS}" "iphoneos" "generic/platform=iOS" "${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_DEVICE}" + build_archive "${SCHEMA_NAME__ADJUST_IOS}" "iphonesimulator" "generic/platform=iOS Simulator" "${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_SIMULATOR}" + IOS_BCSYMBOLS=$(generate_bcsymbols_command_parameter "${ARCHIVE_NAME__IOS_DEVICE}" "${XCF_OUTPUT_FOLDER}") + fi + + if [[ $BUILD_TARGET_TVOS -eq 1 ]] + then + build_archive "${SCHEMA_NAME__ADJUST_TV}" "appletvos" "generic/platform=tvOS" "${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_DEVICE}" + build_archive "${SCHEMA_NAME__ADJUST_TV}" "appletvsimulator" "generic/platform=tvOS Simulator" "${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_SIMULATOR}" + TV_BCSYMBOLS=$(generate_bcsymbols_command_parameter "${ARCHIVE_NAME__TV_DEVICE}" "${XCF_OUTPUT_FOLDER}") + fi + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Creating Dynamic XCFramework for ${TRAGET_PLATFORM_DESCRIPTION} ...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + + if [[ $BUILD_TARGET_IOS -eq 1 ]] && [[ $BUILD_TARGET_TVOS -eq 1 ]] + then + if [[ $XCODE12PLUS > 0 ]]; then + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_DEVICE}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_IOS}.framework" \ + -debug-symbols "$(pwd -P)/${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_DEVICE}.xcarchive/dSYMs/${XCF_FRM_NAME__ADJUST_IOS}.framework.dSYM" \ + ${IOS_BCSYMBOLS} \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_SIMULATOR}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_IOS}.framework" \ + -debug-symbols "$(pwd -P)/${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_SIMULATOR}.xcarchive/dSYMs/${XCF_FRM_NAME__ADJUST_IOS}.framework.dSYM" \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_DEVICE}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_TV}.framework" \ + -debug-symbols "$(pwd -P)/${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_DEVICE}.xcarchive/dSYMs/${XCF_FRM_NAME__ADJUST_TV}.framework.dSYM" \ + ${TV_BCSYMBOLS} \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_SIMULATOR}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_TV}.framework" \ + -debug-symbols "$(pwd -P)/${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_SIMULATOR}.xcarchive/dSYMs/${XCF_FRM_NAME__ADJUST_TV}.framework.dSYM" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_IOS}.xcframework" + else + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_DEVICE}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_IOS}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_SIMULATOR}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_IOS}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_DEVICE}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_TV}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_SIMULATOR}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_TV}.framework" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_IOS}.xcframework" + fi + elif [[ $BUILD_TARGET_IOS -eq 1 ]] + then + if [[ $XCODE12PLUS > 0 ]]; then + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_DEVICE}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_IOS}.framework" \ + -debug-symbols "$(pwd -P)/${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_DEVICE}.xcarchive/dSYMs/${XCF_FRM_NAME__ADJUST_IOS}.framework.dSYM" \ + ${IOS_BCSYMBOLS} \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_SIMULATOR}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_IOS}.framework" \ + -debug-symbols "$(pwd -P)/${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_SIMULATOR}.xcarchive/dSYMs/${XCF_FRM_NAME__ADJUST_IOS}.framework.dSYM" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_IOS}.xcframework" + else + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_DEVICE}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_IOS}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_SIMULATOR}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_IOS}.framework" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_IOS}.xcframework" + fi + elif [[ $BUILD_TARGET_TVOS -eq 1 ]] + then + if [[ $XCODE12PLUS > 0 ]]; then + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_DEVICE}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_TV}.framework" \ + -debug-symbols "$(pwd -P)/${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_DEVICE}.xcarchive/dSYMs/${XCF_FRM_NAME__ADJUST_TV}.framework.dSYM" \ + ${TV_BCSYMBOLS} \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_SIMULATOR}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_TV}.framework" \ + -debug-symbols "$(pwd -P)/${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_SIMULATOR}.xcarchive/dSYMs/${XCF_FRM_NAME__ADJUST_TV}.framework.dSYM" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_TV}.xcframework" + else + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_DEVICE}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_TV}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_SIMULATOR}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_TV}.framework" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_TV}.xcframework" + fi + fi + + # Cleanup archive files + if [[ $BUILD_TARGET_IOS -eq 1 ]] + then + rm -rf "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_DEVICE}.xcarchive" + rm -rf "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IOS_SIMULATOR}.xcarchive" + fi + + if [[ $BUILD_TARGET_TVOS -eq 1 ]] + then + rm -rf "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_DEVICE}.xcarchive" + rm -rf "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__TV_SIMULATOR}.xcarchive" + fi + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Archiving (ZIP) Dynamic XCFramework for ${TRAGET_PLATFORM_DESCRIPTION} ...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + + # VERIFY + + if [[ $BUILD_TARGET_IOS -eq 1 ]] + then + archive_framework "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}" "${XCF_FRM_NAME__ADJUST_IOS}.xcframework" "${XCF_FRM_ZIP_NAME__IOS_TV_DYNAMIC}.xcframework.zip" + else + archive_framework "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}" "${XCF_FRM_NAME__ADJUST_TV}.xcframework" "${XCF_FRM_ZIP_NAME__TV_DYNAMIC}.xcframework.zip" + fi + +fi + +# = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = + +if [[ $BUILD_TARGET_IM -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Building Xcode archives for iOS (iMessage) ...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = ="${NC} + build_archive "${SCHEMA_NAME__ADJUST_IM}" "iphoneos" "generic/platform=iOS" "${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IM_DEVICE}" + build_archive "${SCHEMA_NAME__ADJUST_IM}" "iphonesimulator" "generic/platform=iOS Simulator" "${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IM_SIMULATOR}" + + IM_IOS_BCSYMBOLS=$(generate_bcsymbols_command_parameter "${ARCHIVE_NAME__IM_DEVICE}" "${XCF_OUTPUT_FOLDER}") + + # Create XCFramework + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Creating Dynamic XCFramework for iOS (iMessage) ...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + + if [[ $XCODE12PLUS > 0 ]]; then + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IM_DEVICE}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_IM}.framework" \ + -debug-symbols "$(pwd -P)/${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IM_DEVICE}.xcarchive/dSYMs/${XCF_FRM_NAME__ADJUST_IM}.framework.dSYM" \ + ${IM_IOS_BCSYMBOLS} \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IM_SIMULATOR}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_IM}.framework" \ + -debug-symbols "$(pwd -P)/${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IM_SIMULATOR}.xcarchive/dSYMs/${XCF_FRM_NAME__ADJUST_IM}.framework.dSYM" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_IM}.xcframework" + else + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IM_DEVICE}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_IM}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IM_SIMULATOR}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_IM}.framework" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_IM}.xcframework" + fi + + # Cleanup archive files + rm -rf "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IM_DEVICE}.xcarchive" + rm -rf "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__IM_SIMULATOR}.xcarchive" + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Archiving (ZIP) Dynamic XCFramework for iOS (iMessage) ...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + archive_framework "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}" "${XCF_FRM_NAME__ADJUST_IM}.xcframework" "${XCF_FRM_ZIP_NAME__IM_DYNAMIC}.xcframework.zip" +fi + +# = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = + +if [[ $BUILD_TARGET_WEB_BRIDGE -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Building Xcode archives for iOS (WebBridge) ...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + build_archive "${SCHEMA_NAME__ADJUST_WEB_BRIDGE}" "iphoneos" "generic/platform=iOS" "${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__WEB_DEVICE}" + build_archive "${SCHEMA_NAME__ADJUST_WEB_BRIDGE}" "iphonesimulator" "generic/platform=iOS Simulator" "${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__WEB_SIMULATOR}" + + WEB_IOS_BCSYMBOLS=$(generate_bcsymbols_command_parameter "${ARCHIVE_NAME__WEB_DEVICE}" "${XCF_OUTPUT_FOLDER}") + + # Create XCFramework + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Creating Dynamic XCFramework for iOS (WebBridge) ...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + + if [[ $XCODE12PLUS > 0 ]]; then + + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__WEB_DEVICE}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}.framework" \ + -debug-symbols "$(pwd -P)/${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__WEB_DEVICE}.xcarchive/dSYMs/${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}.framework.dSYM" \ + ${WEB_IOS_BCSYMBOLS} \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__WEB_SIMULATOR}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}.framework" \ + -debug-symbols "$(pwd -P)/${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__WEB_SIMULATOR}.xcarchive/dSYMs/${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}.framework.dSYM" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}.xcframework" + + else + + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__WEB_DEVICE}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__WEB_SIMULATOR}.xcarchive/Products/Library/Frameworks/${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}.framework" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}.xcframework" + + fi + + # Cleanup archive files + rm -rf "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__WEB_DEVICE}.xcarchive" + rm -rf "./${XCF_OUTPUT_FOLDER}/${ARCHIVE_NAME__WEB_SIMULATOR}.xcarchive" + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Archiving (ZIP) Dynamic XCFramework for iOS (WebBridge) ...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + archive_framework "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_DYNAMIC_XCFRMK_FOLDER}" "${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}.xcframework" "${XCF_FRM_ZIP_NAME__WEB_BRIDGE_DYNAMIC}.xcframework.zip" +fi + +# = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Dynamic XCFrameworks build - END... ${NC}" diff --git a/scripts/static_frameworks.sh b/scripts/static_frameworks.sh new file mode 100755 index 000000000..e37e40896 --- /dev/null +++ b/scripts/static_frameworks.sh @@ -0,0 +1,51 @@ +#!/usr/bin/env bash + +source ./scripts/build_definitions.sh -fs + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Static Frameworks build - START... ${NC}" + +mkdir -p "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_FRMK_FOLDER}" + +if [[ $BUILD_TARGET_IOS -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Buiding Static Frameworks for iOS...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + build_static_fat_framework "${SCHEMA_NAME__ADJUST_IOS_STATIC}" "ios" "${XCF_FRM_NAME__ADJUST_IOS}" "${XCF_OUTPUT_FOLDER}" "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_FRMK_FOLDER}" "${XCF_FRM_ZIP_NAME__IOS_STATIC}.framework.zip" +else + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Skipping iOS SDK framework build ... ${NC}" +fi + +if [[ $BUILD_TARGET_TVOS -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Buiding static Frameworks for tvOS...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + build_static_fat_framework "${SCHEMA_NAME__ADJUST_TV_STATIC}" "tvos" "${XCF_FRM_NAME__ADJUST_TV}" "${XCF_OUTPUT_FOLDER}" "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_FRMK_FOLDER}" "${XCF_FRM_ZIP_NAME__TV_STATIC}.framework.zip" +else + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Skipping tvOS SDK framework build ... ${NC}" +fi + +if [[ $BUILD_TARGET_IM -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Buiding static Frameworks for iOS (iMessage)...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + build_static_fat_framework "${SCHEMA_NAME__ADJUST_IM_STATIC}" "ios" "${XCF_FRM_NAME__ADJUST_IM}" "${XCF_OUTPUT_FOLDER}" "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_FRMK_FOLDER}" "${XCF_FRM_ZIP_NAME__IM_STATIC}.framework.zip" +else + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Skipping iMessage SDK framework build ... ${NC}" +fi + +if [[ $BUILD_TARGET_WEB_BRIDGE -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Buiding static Frameworks for iOS (WebBridge)...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + build_static_fat_framework "${SCHEMA_NAME__ADJUST_WEB_BRIDGE_STATIC}" "ios" "${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}" "${XCF_OUTPUT_FOLDER}" "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_FRMK_FOLDER}" "${XCF_FRM_ZIP_NAME__WEB_BRIDGE_STATIC}.framework.zip" +else + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Skipping iOS (WebBridge) SDK framework build ... ${NC}" +fi + + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Static Frameworks build - END... ${NC}" + diff --git a/scripts/static_xcframeworks.sh b/scripts/static_xcframeworks.sh new file mode 100755 index 000000000..2e60e5df2 --- /dev/null +++ b/scripts/static_xcframeworks.sh @@ -0,0 +1,170 @@ +#!/usr/bin/env bash + +source ./scripts/build_definitions.sh -xs + +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Static XCFrameworks build - START... ${NC}" + +if [[ $BUILD_TARGET_IOS -eq 1 ]] || [[ $BUILD_TARGET_TVOS -eq 1 ]] +then + + TRAGET_PLATFORM_DESCRIPTION="" + if [[ $BUILD_TARGET_IOS -eq 1 ]] && [[ $BUILD_TARGET_TVOS -eq 1 ]] + then + TRAGET_PLATFORM_DESCRIPTION="iOS and tvOS" + elif [[ $BUILD_TARGET_IOS -eq 1 ]] + then + TRAGET_PLATFORM_DESCRIPTION="iOS" + elif [[ $BUILD_TARGET_TVOS -eq 1 ]] + then + TRAGET_PLATFORM_DESCRIPTION="tvOS" + fi + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Buiding Static XCFramework for ${TRAGET_PLATFORM_DESCRIPTION} ...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + + + if [[ $BUILD_TARGET_IOS -eq 1 ]] + then + xcodebuild -configuration Release \ + -target "${SCHEMA_NAME__ADJUST_IOS_STATIC}" \ + -sdk iphonesimulator \ + build + + xcodebuild -configuration Release \ + -target "${SCHEMA_NAME__ADJUST_IOS_STATIC}" \ + -sdk iphoneos \ + build + fi + + + if [[ $BUILD_TARGET_TVOS -eq 1 ]] + then + xcodebuild -configuration Release \ + -target "${SCHEMA_NAME__ADJUST_TV_STATIC}" \ + -sdk appletvsimulator \ + build + + xcodebuild -configuration Release \ + -target "${SCHEMA_NAME__ADJUST_TV_STATIC}" \ + -sdk appletvos \ + build + + fi + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Buiding Static XCFramework for ${TRAGET_PLATFORM_DESCRIPTION} ...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + + if [[ $BUILD_TARGET_IOS -eq 1 ]] && [[ $BUILD_TARGET_TVOS -eq 1 ]] + then + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_IOS_STATIC}/iphoneos/${XCF_FRM_NAME__ADJUST_IOS}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_IOS_STATIC}/iphonesimulator/${XCF_FRM_NAME__ADJUST_IOS}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_TV_STATIC}/appletvos/${XCF_FRM_NAME__ADJUST_TV}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_TV_STATIC}/appletvsimulator/${XCF_FRM_NAME__ADJUST_TV}.framework" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_IOS}.xcframework" + + # Cleanup built frameworks + rm -rf "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_IOS_STATIC}" + rm -rf "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_TV_STATIC}" + elif [[ $BUILD_TARGET_IOS -eq 1 ]] + then + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_IOS_STATIC}/iphoneos/${XCF_FRM_NAME__ADJUST_IOS}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_IOS_STATIC}/iphonesimulator/${XCF_FRM_NAME__ADJUST_IOS}.framework" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_IOS}.xcframework" + + # Cleanup built frameworks + rm -rf "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_IOS_STATIC}" + elif [[ $BUILD_TARGET_TVOS -eq 1 ]] + then + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_TV_STATIC}/appletvos/${XCF_FRM_NAME__ADJUST_TV}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_TV_STATIC}/appletvsimulator/${XCF_FRM_NAME__ADJUST_TV}.framework" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_TV}.xcframework" + + # Cleanup built frameworks + rm -rf "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_TV_STATIC}" + fi + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Archiving (ZIP) Static XCFramework for ${TRAGET_PLATFORM_DESCRIPTION} ...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + + if [[ $BUILD_TARGET_IOS -eq 1 ]] + then + archive_framework "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_XCFRMK_FOLDER}" "${XCF_FRM_NAME__ADJUST_IOS}.xcframework" "${XCF_FRM_ZIP_NAME__IOS_TV_STATIC}.xcframework.zip" + else + archive_framework "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_XCFRMK_FOLDER}" "${XCF_FRM_NAME__ADJUST_TV}.xcframework" "${XCF_FRM_ZIP_NAME__TV_STATIC}.xcframework.zip" + fi + +fi + +# = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = + +if [[ $BUILD_TARGET_IM -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Buiding Static XCFramework for iOS (iMessage)...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + + xcodebuild -configuration Release \ + -target ${SCHEMA_NAME__ADJUST_IM_STATIC} \ + -sdk iphonesimulator \ + build + + xcodebuild -configuration Release \ + -target ${SCHEMA_NAME__ADJUST_IM_STATIC} \ + -sdk iphoneos \ + build + + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_IM_STATIC}/iphoneos/${XCF_FRM_NAME__ADJUST_IM}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_IM_STATIC}/iphonesimulator/${XCF_FRM_NAME__ADJUST_IM}.framework" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_IM}.xcframework" + + # Cleanup built frameworks + rm -rf "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_IM_STATIC}" + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Archiving (ZIP) Static XCFramework for iOS (iMessage)...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + archive_framework "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_XCFRMK_FOLDER}" "${XCF_FRM_NAME__ADJUST_IM}.xcframework" "${XCF_FRM_ZIP_NAME__IM_STATIC}.xcframework.zip" +fi + + +# = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = + +if [[ $BUILD_TARGET_WEB_BRIDGE -eq 1 ]] +then + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Buiding Static XCFramework for iOS (WebBridge)...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + + xcodebuild -configuration Release \ + -target ${SCHEMA_NAME__ADJUST_WEB_BRIDGE_STATIC} \ + -sdk iphonesimulator \ + build + + xcodebuild -configuration Release \ + -target ${SCHEMA_NAME__ADJUST_WEB_BRIDGE_STATIC} \ + -sdk iphoneos \ + build + + xcodebuild -create-xcframework \ + -framework "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_WEB_BRIDGE_STATIC}/iphoneos/${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}.framework" \ + -framework "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_WEB_BRIDGE_STATIC}/iphonesimulator/${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}.framework" \ + -output "./${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_XCFRMK_FOLDER}/${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}.xcframework" + + # Cleanup built frameworks + rm -rf "./${XCF_OUTPUT_FOLDER}/${SCHEMA_NAME__ADJUST_WEB_BRIDGE_STATIC}" + + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} XCFramework: Archiving (ZIP) Static XCFramework for iOS (WebBridge)...${NC}" + echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =${NC}" + archive_framework "${XCF_OUTPUT_FOLDER}/${XCF_OUTPUT_STATIC_XCFRMK_FOLDER}" "${XCF_FRM_NAME__ADJUST_WEB_BRIDGE}.xcframework" "${XCF_FRM_ZIP_NAME__WEB_BRIDGE_STATIC}.xcframework.zip" +fi + +# = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +echo -e "${CYAN}[ADJUST][BUILD]:${GREEN} Static XCFrameworks build - END... ${NC}"