Skip to content
This repository has been archived by the owner on Dec 2, 2024. It is now read-only.

Commit

Permalink
IOS-7346 Connect ScaleCodec, TweetNacl and TonSwift via SPM (#770)
Browse files Browse the repository at this point in the history
  • Loading branch information
fedorov-d authored Jul 15, 2024
1 parent c544a96 commit 07938e5
Show file tree
Hide file tree
Showing 5 changed files with 110 additions and 37 deletions.
3 changes: 0 additions & 3 deletions BlockchainSdk.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -43,15 +43,12 @@ Use BlockchainSdk for Tangem wallet integration
# 'TangemWalletCore' dependency must be added via SPM

s.dependency 'TangemSdk'
s.dependency 'BigInt', '5.2.0'
s.dependency 'SwiftyJSON', '5.0.1'
s.dependency 'Moya', '15.0.0'
s.dependency 'Sodium', '0.9.1'
s.dependency 'SwiftCBOR', '0.4.5'
s.dependency 'stellar-ios-mac-sdk', '2.5.4'
s.dependency 'AnyCodable-FlightSchool', '0.6.7'
s.dependency 'ScaleCodec', '0.2.1'
s.dependency 'TonSwift', '1.0.10'

s.dependency 'BinanceChain' # Fork https://github.com/tangem/swiftbinancechain.git
s.dependency 'BitcoinCore.swift' # Fork https://github.com/tangem/bitcoincore.git
Expand Down
59 changes: 59 additions & 0 deletions BlockchainSdk.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@
0A7C5BFD2C174E7700B32CA5 /* OnfinalityAPIResolver.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0A7C5BFC2C174E7700B32CA5 /* OnfinalityAPIResolver.swift */; };
0A92275F2C16E5D500CB7777 /* BittensorExternalLinkProvider.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0A92275E2C16E5D500CB7777 /* BittensorExternalLinkProvider.swift */; };
0AA9E3792B9A03450084E8A7 /* MantaExternalLinkProvider.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0AA9E3782B9A03450084E8A7 /* MantaExternalLinkProvider.swift */; };
0ABC60F02C4101ED00065EBA /* TonSwift in Frameworks */ = {isa = PBXBuildFile; productRef = 0ABC60EF2C4101ED00065EBA /* TonSwift */; };
0ABC60F32C41021000065EBA /* ScaleCodec in Frameworks */ = {isa = PBXBuildFile; productRef = 0ABC60F22C41021000065EBA /* ScaleCodec */; };
0ABC61042C41040500065EBA /* TweetNacl in Frameworks */ = {isa = PBXBuildFile; productRef = 0ABC61032C41040500065EBA /* TweetNacl */; };
0ABC610B2C4107F000065EBA /* TweetNacl in Frameworks */ = {isa = PBXBuildFile; productRef = 0ABC610A2C4107F000065EBA /* TweetNacl */; };
0AEE1E702C1B1BEA000BFCB2 /* BittensorWalletAssembly.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0AEE1E6F2C1B1BEA000BFCB2 /* BittensorWalletAssembly.swift */; };
0AEFB5392B7656EC007519F9 /* NodeRequest.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0AEFB5382B7656EC007519F9 /* NodeRequest.swift */; };
0AF90CD72B87624800772F04 /* AreonExternalLinkProvider.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0AF90CD62B87624800772F04 /* AreonExternalLinkProvider.swift */; };
Expand Down Expand Up @@ -1747,10 +1751,13 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
0ABC60F32C41021000065EBA /* ScaleCodec in Frameworks */,
B6A2CC432B6C55FE00864CD2 /* secp256k1 in Frameworks */,
0ABC60F02C4101ED00065EBA /* TonSwift in Frameworks */,
BFF1171432045E1915ABA71F /* Pods_BlockchainSdk.framework in Frameworks */,
B66B57662B6C504000320FF9 /* Hedera in Frameworks */,
B66B57732B6C532F00320FF9 /* CryptoSwift in Frameworks */,
0ABC61042C41040500065EBA /* TweetNacl in Frameworks */,
B6A2CC482B6C56D900864CD2 /* SwiftProtobuf in Frameworks */,
B63BAA602B740C8800DA26C9 /* TangemWalletCoreBinariesWrapper in Frameworks */,
);
Expand All @@ -1769,6 +1776,7 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
0ABC610B2C4107F000065EBA /* TweetNacl in Frameworks */,
B63BAA622B740C9200DA26C9 /* TangemWalletCoreBinariesWrapper in Frameworks */,
DA59751E27D749A9009F0A1F /* MapKit.framework in Frameworks */,
B6A2CC452B6C568E00864CD2 /* secp256k1 in Frameworks */,
Expand Down Expand Up @@ -4122,6 +4130,9 @@
B66B57652B6C504000320FF9 /* Hedera */,
B6A2CC472B6C56D900864CD2 /* SwiftProtobuf */,
B63BAA5F2B740C8800DA26C9 /* TangemWalletCoreBinariesWrapper */,
0ABC60EF2C4101ED00065EBA /* TonSwift */,
0ABC60F22C41021000065EBA /* ScaleCodec */,
0ABC61032C41040500065EBA /* TweetNacl */,
);
productName = BlockchainSdk;
productReference = 5D14E46E2397B80F00C15FC8 /* BlockchainSdk.framework */;
Expand Down Expand Up @@ -4168,6 +4179,7 @@
packageProductDependencies = (
B6A2CC442B6C568E00864CD2 /* secp256k1 */,
B63BAA612B740C9200DA26C9 /* TangemWalletCoreBinariesWrapper */,
0ABC610A2C4107F000065EBA /* TweetNacl */,
);
productName = BlockchainSdkExample;
productReference = DA59750827D744A7009F0A1F /* BlockchainSdkExample.app */;
Expand Down Expand Up @@ -4216,6 +4228,9 @@
B66B57642B6C504000320FF9 /* XCRemoteSwiftPackageReference "hedera-sdk-swift" */,
B6A2CC462B6C56D900864CD2 /* XCRemoteSwiftPackageReference "swift-protobuf-binaries" */,
B66B575B2B6C4ECD00320FF9 /* XCRemoteSwiftPackageReference "wallet-core-binaries-ios" */,
0ABC60EE2C4101ED00065EBA /* XCRemoteSwiftPackageReference "ton-swift" */,
0ABC60F12C41021000065EBA /* XCRemoteSwiftPackageReference "ScaleCodec" */,
0ABC60FE2C4103A600065EBA /* XCRemoteSwiftPackageReference "tweetnacl-swiftwrap" */,
);
productRefGroup = 5D14E46F2397B80F00C15FC8 /* Products */;
projectDirPath = "";
Expand Down Expand Up @@ -5630,6 +5645,30 @@
/* End XCConfigurationList section */

/* Begin XCRemoteSwiftPackageReference section */
0ABC60EE2C4101ED00065EBA /* XCRemoteSwiftPackageReference "ton-swift" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/tangem/ton-swift.git";
requirement = {
kind = exactVersion;
version = "1.0.10-tangem1";
};
};
0ABC60F12C41021000065EBA /* XCRemoteSwiftPackageReference "ScaleCodec" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/tesseract-one/ScaleCodec.swift";
requirement = {
kind = exactVersion;
version = 0.2.1;
};
};
0ABC60FE2C4103A600065EBA /* XCRemoteSwiftPackageReference "tweetnacl-swiftwrap" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/bitmark-inc/tweetnacl-swiftwrap.git";
requirement = {
kind = upToNextMinorVersion;
minimumVersion = 1.1.0;
};
};
B66B575B2B6C4ECD00320FF9 /* XCRemoteSwiftPackageReference "wallet-core-binaries-ios" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/tangem/wallet-core-binaries-ios.git";
Expand Down Expand Up @@ -5673,6 +5712,26 @@
/* End XCRemoteSwiftPackageReference section */

/* Begin XCSwiftPackageProductDependency section */
0ABC60EF2C4101ED00065EBA /* TonSwift */ = {
isa = XCSwiftPackageProductDependency;
package = 0ABC60EE2C4101ED00065EBA /* XCRemoteSwiftPackageReference "ton-swift" */;
productName = TonSwift;
};
0ABC60F22C41021000065EBA /* ScaleCodec */ = {
isa = XCSwiftPackageProductDependency;
package = 0ABC60F12C41021000065EBA /* XCRemoteSwiftPackageReference "ScaleCodec" */;
productName = ScaleCodec;
};
0ABC61032C41040500065EBA /* TweetNacl */ = {
isa = XCSwiftPackageProductDependency;
package = 0ABC60FE2C4103A600065EBA /* XCRemoteSwiftPackageReference "tweetnacl-swiftwrap" */;
productName = TweetNacl;
};
0ABC610A2C4107F000065EBA /* TweetNacl */ = {
isa = XCSwiftPackageProductDependency;
package = 0ABC60FE2C4103A600065EBA /* XCRemoteSwiftPackageReference "tweetnacl-swiftwrap" */;
productName = TweetNacl;
};
B63BAA5F2B740C8800DA26C9 /* TangemWalletCoreBinariesWrapper */ = {
isa = XCSwiftPackageProductDependency;
package = B66B575B2B6C4ECD00320FF9 /* XCRemoteSwiftPackageReference "wallet-core-binaries-ios" */;
Expand Down
38 changes: 37 additions & 1 deletion BlockchainSdk.xcworkspace/xcshareddata/swiftpm/Package.resolved
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"originHash" : "09ecb99db3e580b585d5d932184af81c65d50399b08821d46e7de1ac03c0fdd2",
"originHash" : "336688749094918bc44fd9820378abd48013483cfc95431dcdd1a02334fd5d02",
"pins" : [
{
"identity" : "anyasyncsequence",
Expand All @@ -10,6 +10,15 @@
"version" : "1.0.2"
}
},
{
"identity" : "bigint",
"kind" : "remoteSourceControl",
"location" : "https://github.com/attaswift/BigInt",
"state" : {
"revision" : "0ed110f7555c34ff468e72e1686e59721f2b0da6",
"version" : "5.3.0"
}
},
{
"identity" : "cryptoswift",
"kind" : "remoteSourceControl",
Expand Down Expand Up @@ -37,6 +46,15 @@
"version" : "0.26.0-tangem3"
}
},
{
"identity" : "scalecodec.swift",
"kind" : "remoteSourceControl",
"location" : "https://github.com/tesseract-one/ScaleCodec.swift",
"state" : {
"revision" : "bd39b2d68d87126a61b62a071ee4c065e2a1fe30",
"version" : "0.2.1"
}
},
{
"identity" : "secp256k1.swift",
"kind" : "remoteSourceControl",
Expand Down Expand Up @@ -163,6 +181,24 @@
"version" : "1.2.1"
}
},
{
"identity" : "ton-swift",
"kind" : "remoteSourceControl",
"location" : "https://github.com/tangem/ton-swift.git",
"state" : {
"revision" : "7030234ff239796c5f71f0e65eb4e9ffec5a83cb",
"version" : "1.0.10-tangem1"
}
},
{
"identity" : "tweetnacl-swiftwrap",
"kind" : "remoteSourceControl",
"location" : "https://github.com/bitmark-inc/tweetnacl-swiftwrap",
"state" : {
"revision" : "f8fd111642bf2336b11ef9ea828510693106e954",
"version" : "1.1.0"
}
},
{
"identity" : "wallet-core-binaries-ios",
"kind" : "remoteSourceControl",
Expand Down
13 changes: 9 additions & 4 deletions Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,16 @@ target 'BlockchainSdk' do
# 'SwiftProtobuf' dependency must be added via SPM
# 'secp256k1.swift' dependency must be added via SPM

pod 'BigInt', '5.2.0'
pod 'Moya', '15.0.0'
pod 'Sodium', '0.9.1'
pod 'SwiftCBOR', '0.4.5'
pod 'AnyCodable-FlightSchool', '0.6.7'
pod 'stellar-ios-mac-sdk', '2.5.4'
pod 'ScaleCodec', '0.2.1'
pod 'TonSwift', :git => 'https://github.com/tangem/ton-swift.git', :tag => '1.0.10-tangem1'

pod 'BinanceChain', :git => 'https://github.com/tangem/swiftbinancechain.git', :tag => '0.0.11'
#pod 'BinanceChain', :path => '../SwiftBinanceChain'

pod 'Solana.Swift', :git => 'https://github.com/tangem/Solana.Swift', :tag => '1.2.0-tangem9'
pod 'Solana.Swift', :git => 'https://github.com/tangem/Solana.Swift', :tag => '1.2.0-tangem10'
#pod 'Solana.Swift', :path => '../Solana.Swift'

pod 'SwiftyJSON', :git => 'https://github.com/tangem/SwiftyJSON.git', :tag => '5.0.1-tangem1'
Expand Down Expand Up @@ -87,6 +84,14 @@ post_install do |installer|
"secp256k1",
{ :kind => "upToNextMinorVersion", :minimumVersion => "0.12.0" }
)

add_spm_package_to_target(
installer.pods_project,
"Solana.Swift",
"https://github.com/bitmark-inc/tweetnacl-swiftwrap.git",
"TweetNacl",
{ :kind => "exactVersion", :version => "1.1.0" }
)

end

Expand Down
34 changes: 5 additions & 29 deletions Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
PODS:
- Alamofire (5.9.1)
- AnyCodable-FlightSchool (0.6.7)
- BigInt (5.2.0)
- BinanceChain (1.0.1-beta):
- BinanceChain/Core (= 1.0.1-beta)
- BinanceChain/Core (1.0.1-beta):
Expand All @@ -19,51 +18,38 @@ PODS:
- Moya/Core (= 15.0.0)
- Moya/Core (15.0.0):
- Alamofire (~> 5.0)
- ScaleCodec (0.2.1):
- BigInt (~> 5.2)
- Sodium (0.9.1)
- Solana.Swift (1.1):
- Starscream (= 4.0.8)
- TweetNacl (~> 1.0.2)
- Starscream (4.0.8)
- stellar-ios-mac-sdk (2.5.4)
- SwiftCBOR (0.4.5)
- SwiftDate (7.0.0)
- SwiftyJSON (5.0.1)
- TangemSdk (3.8.0)
- TonSwift (1.0.10):
- BigInt
- TweetNacl
- TweetNacl (1.0.2)

DEPENDENCIES:
- AnyCodable-FlightSchool (= 0.6.7)
- BigInt (= 5.2.0)
- BinanceChain (from `https://github.com/tangem/swiftbinancechain.git`, tag `0.0.11`)
- BitcoinCore.swift (from `https://github.com/tangem/bitcoincore.git`, tag `0.0.20`)
- Moya (= 15.0.0)
- ScaleCodec (= 0.2.1)
- Sodium (= 0.9.1)
- Solana.Swift (from `https://github.com/tangem/Solana.Swift`, tag `1.2.0-tangem9`)
- Solana.Swift (from `https://github.com/tangem/Solana.Swift`, tag `1.2.0-tangem10`)
- stellar-ios-mac-sdk (= 2.5.4)
- SwiftCBOR (= 0.4.5)
- SwiftyJSON (from `https://github.com/tangem/SwiftyJSON.git`, tag `5.0.1-tangem1`)
- TangemSdk (from `https://github.com/Tangem/tangem-sdk-ios.git`, tag `develop-264`)
- TonSwift (from `https://github.com/tangem/ton-swift.git`, tag `1.0.10-tangem1`)

SPEC REPOS:
trunk:
- Alamofire
- AnyCodable-FlightSchool
- BigInt
- Moya
- ScaleCodec
- Sodium
- Starscream
- stellar-ios-mac-sdk
- SwiftCBOR
- SwiftDate
- TweetNacl

EXTERNAL SOURCES:
BinanceChain:
Expand All @@ -74,16 +60,13 @@ EXTERNAL SOURCES:
:tag: 0.0.20
Solana.Swift:
:git: https://github.com/tangem/Solana.Swift
:tag: 1.2.0-tangem9
:tag: 1.2.0-tangem10
SwiftyJSON:
:git: https://github.com/tangem/SwiftyJSON.git
:tag: 5.0.1-tangem1
TangemSdk:
:git: https://github.com/Tangem/tangem-sdk-ios.git
:tag: develop-264
TonSwift:
:git: https://github.com/tangem/ton-swift.git
:tag: 1.0.10-tangem1

CHECKOUT OPTIONS:
BinanceChain:
Expand All @@ -94,36 +77,29 @@ CHECKOUT OPTIONS:
:tag: 0.0.20
Solana.Swift:
:git: https://github.com/tangem/Solana.Swift
:tag: 1.2.0-tangem9
:tag: 1.2.0-tangem10
SwiftyJSON:
:git: https://github.com/tangem/SwiftyJSON.git
:tag: 5.0.1-tangem1
TangemSdk:
:git: https://github.com/Tangem/tangem-sdk-ios.git
:tag: develop-264
TonSwift:
:git: https://github.com/tangem/ton-swift.git
:tag: 1.0.10-tangem1

SPEC CHECKSUMS:
Alamofire: f36a35757af4587d8e4f4bfa223ad10be2422b8c
AnyCodable-FlightSchool: 261cbe76757802b17d471b9059b21e6fa5edf57b
BigInt: f668a80089607f521586bbe29513d708491ef2f7
BinanceChain: f727abc7a20ba71f4497e46b7400124027b25692
BitcoinCore.swift: 64ac4e69d9a6ef917bcbb0c23f1324cf57a822fb
Moya: 138f0573e53411fb3dc17016add0b748dfbd78ee
ScaleCodec: 5d7d0439940c600f49babad6ea265a09377c404b
Sodium: 23d11554ecd556196d313cf6130d406dfe7ac6da
Solana.Swift: 9be6d68bb57d679344b8c7d190458f0b1de92611
Solana.Swift: b926815c93f483628ce51d9a51c96567ae14709e
Starscream: 19b5533ddb925208db698f0ac508a100b884a1b9
stellar-ios-mac-sdk: 01055b326a62d1e9bb50999eadeb85c9dec60658
SwiftCBOR: ac340b74d3b2cf1f8884bb748bd09875848e3873
SwiftDate: bbc26e26fc8c0c33fbee8c140c5e8a68293a148a
SwiftyJSON: c0bd75b5969785b3d9ae41d5709fe75bc5de4002
TangemSdk: f3adf8d0c18bf7a76406462fa31c0efa9f2efa93
TonSwift: 4bec2e932ae922f1e0419bdfd6d59dace5c63a31
TweetNacl: 3abf4d1d2082b0114e7a67410e300892448951e6

PODFILE CHECKSUM: 084a848d67965b45a8790e23f6719ab1c97f604c
PODFILE CHECKSUM: 52792b492481e3a4e4dcf8ac0ecb1cffe929ad2c

COCOAPODS: 1.15.2

0 comments on commit 07938e5

Please sign in to comment.