# # To learn more about a Podspec see http://guides.cocoapods.org/syntax/podspec.html. # Run `pod lib lint tor.podspec` to validate before publishing. # Pod::Spec.new do |s| s.name = 'tor' s.version = '0.0.1' s.summary = 'A new Flutter FFI plugin project.' s.description = <<-DESC A new Flutter FFI plugin project. DESC s.homepage = 'http://example.com' s.license = { :file => '../LICENSE' } s.author = { 'Your Company' => 'email@example.com' } s.source = { :path => '.' } s.source_files = 'Classes/**/*' s.platform = :osx, '10.13' s.script_phase = { :name => 'Build Rust library', # First argument is relative path to the `rust` folder, second is name of rust library :script => 'sh "$PODS_TARGET_SRCROOT/../cargokit/build_pod.sh" ../rust tor', :execution_position => :before_compile, :input_files => ['${BUILT_PRODUCTS_DIR}/cargokit_phony'], # Let XCode know that the static library referenced in -force_load below is # created by this build step. :output_files => ["${BUILT_PRODUCTS_DIR}/libtor.a"], } s.pod_target_xcconfig = { 'DEFINES_MODULE' => 'YES', # We use `-force_load` instead of `-l` since Xcode strips out unused symbols from static libraries. 'OTHER_LDFLAGS' => '-force_load ${BUILT_PRODUCTS_DIR}/libtor.a', 'DEAD_CODE_STRIPPING' => 'YES', 'STRIP_INSTALLED_PRODUCT[config=Release][sdk=*][arch=*]' => "YES", 'STRIP_STYLE[config=Release][sdk=*][arch=*]' => "non-global", 'DEPLOYMENT_POSTPROCESSING[config=Release][sdk=*][arch=*]' => "YES", } end