Add .travis.yml, fix podspec bugs

This commit is contained in:
Koray Koska 2018-02-16 02:40:52 +01:00
parent d65c64d12a
commit a4d5a20fd6
4 changed files with 17 additions and 11 deletions

View File

@ -2,13 +2,15 @@
# * http://www.objc.io/issue-6/travis-ci.html # * http://www.objc.io/issue-6/travis-ci.html
# * https://github.com/supermarin/xcpretty#usage # * https://github.com/supermarin/xcpretty#usage
osx_image: xcode7.3 osx_image: xcode9.2
xcode_sdk: iphonesimulator11.2
language: objective-c language: objective-c
# cache: cocoapods # cache: cocoapods
# podfile: Example/Podfile # podfile: Example/Podfile
# before_install: before_install:
# - gem install cocoapods # Since Travis is not always on latest version - gem install cocoapods # Since Travis is not always on latest version
# - pod install --project-directory=Example - pod repo update
- pod install --project-directory=Example
script: script:
- set -o pipefail && xcodebuild test -enableCodeCoverage YES -workspace Example/secp256k1.xcworkspace -scheme secp256k1-Example -sdk iphonesimulator9.3 ONLY_ACTIVE_ARCH=NO | xcpretty - set -o pipefail && xcodebuild test -enableCodeCoverage YES -workspace Example/secp256k1.xcworkspace -scheme secp256k1-Example -sdk iphonesimulator11.2 -destination 'platform=iOS Simulator,name=iPhone 6,OS=11.2' ONLY_ACTIVE_ARCH=NO | xcpretty
- pod lib lint - pod lib lint

View File

@ -9,7 +9,7 @@
Pod::Spec.new do |s| Pod::Spec.new do |s|
s.name = 'secp256k1' s.name = 'secp256k1'
s.version = '0.1.0' s.version = '0.1.0'
s.summary = 'A short description of secp256k1.' s.summary = 'secp256k1 bindings for swift. Cocoapods, Carthage and SPM support. Linux support.'
# This description is used to generate tags and improve search results. # This description is used to generate tags and improve search results.
# * Think: What does it do? Why did you write it? What is the focus? # * Think: What does it do? Why did you write it? What is the focus?
@ -18,7 +18,8 @@ Pod::Spec.new do |s|
# * Finally, don't worry about the indent, CocoaPods strips it! # * Finally, don't worry about the indent, CocoaPods strips it!
s.description = <<-DESC s.description = <<-DESC
TODO: Add long description of the pod here. This pod binds the bitcoin-core library, the ECDSA curve, secp256k1 into Swift. This curve is used for
Bitcoin, Ethereum and many other Cryptocurrency Signature generation and verification.
DESC DESC
s.homepage = 'https://github.com/Boilertalk/secp256k1.swift' s.homepage = 'https://github.com/Boilertalk/secp256k1.swift'
@ -29,6 +30,9 @@ TODO: Add long description of the pod here.
# s.social_media_url = 'https://twitter.com/<TWITTER_USERNAME>' # s.social_media_url = 'https://twitter.com/<TWITTER_USERNAME>'
s.ios.deployment_target = '8.0' s.ios.deployment_target = '8.0'
s.osx.deployment_target = '10.10'
s.tvos.deployment_target = '9.0'
s.watchos.deployment_target = '2.0'
s.module_name = 'secp256k1' s.module_name = 'secp256k1'
@ -48,10 +52,10 @@ TODO: Add long description of the pod here.
sed -i '' -e 's:contrib/::g' ./**/**/**/**/*.c sed -i '' -e 's:contrib/::g' ./**/**/**/**/*.c
sed -i '' -e 's:contrib/::g' ./**/**/**/**/*.c sed -i '' -e 's:contrib/::g' ./**/**/**/**/*.c
sed -i '' -e 's:libsecp256k1-config.h:../../libsecp256k1-config.h:g' ./**/**/**/**/*.c sed -i '' -e 's:libsecp256k1-config.h:../../secp256k1-config.h:g' ./**/**/**/**/*.c
sed -i '' -e 's:libsecp256k1-config.h:../../libsecp256k1-config.h:g' ./**/**/**/**/*.h sed -i '' -e 's:libsecp256k1-config.h:../../secp256k1-config.h:g' ./**/**/**/**/*.h
sed -i '' -e 's:ecmult_static_context.h:../../ecmult_static_context.h:g' ./**/**/**/**/*.h sed -i '' -e 's:ecmult_static_context.h:../../secp256k1_ec_mult_static_context.h:g' ./**/**/**/**/*.h
CMD CMD
s.source_files = 'secp256k1/Classes/secp256k1/{src,include,contrib}/*.{h,c}', 'secp256k1/Classes/secp256k1/src/modules/{recovery,ecdh}/*.{h,c}', 'secp256k1_ios/Classes/libsecp256k1-config.h', 'secp256k1_ios/Classes/secp256k1.h', 'secp256k1/Classes/ecmult_static_context.h.h' s.source_files = 'secp256k1/Classes/secp256k1/{src,include,contrib}/*.{h,c}', 'secp256k1/Classes/secp256k1/src/modules/{recovery,ecdh}/*.{h,c}', 'secp256k1_ios/Classes/libsecp256k1-config.h', 'secp256k1_ios/Classes/secp256k1.h', 'secp256k1/Classes/ecmult_static_context.h.h'