cawfree / web3-react-native

⚛️ Web3 Native Modules for React Native.
MIT License
62 stars 9 forks source link

Unable to include web3swift as a Podspec dependency #1

Open cawfree opened 4 years ago

cawfree commented 4 years ago

Issue

It is not possible to install web3swift in web3-react-native.podspec because it relies on us to specify :modular_headers => true, which the linter does not recognize:

s.dependency 'secp256k1.c', '0.1.2', :modular_headers => true
s.dependency 'web3swift', '2.2.1', :modular_headers => true

However, when doing this, executing pod install throws the following error:

[!] Invalid `Podfile` file: 
[!] Invalid `web3-react-native.podspec` file: [!] Unsupported version requirements. ["0.1.2", {:modular_headers=>true}] is not valid.

Workaround

Specify these dependencies manually in the App's Podfile:

pod 'secp256k1.c', '0.1.2', :modular_headers => true
pod 'web3swift', '2.2.1', :modular_headers => true

This is not acceptable though, because React Native libraries (>0.60) should not necessitate any manual configuration of the Podfile.