diff --git a/lib/cocoapods-packager/builder.rb b/lib/cocoapods-packager/builder.rb index 4ecbd31..76b1c94 100755 --- a/lib/cocoapods-packager/builder.rb +++ b/lib/cocoapods-packager/builder.rb @@ -144,10 +144,10 @@ def build_static_library_for_ios(output) static_libs = static_libs_in_sandbox('build') + static_libs_in_sandbox('build-sim') + vendored_libraries libs = ios_architectures.map do |arch| library = "#{@static_sandbox_root}/build/package-#{arch}.a" - `libtool -arch_only #{arch} -static -o #{library} #{static_libs.join(' ')}` - library - end - + `libtool -arch_only #{arch} -static -o #{library} #{static_libs.join(' ')} 2> /dev/null` + library if File.exist?(library) + end.compact + `lipo -create -output #{output} #{libs.join(' ')}` end @@ -290,7 +290,7 @@ def vendored_libraries libs = file_accessors.flat_map(&:vendored_static_frameworks).map { |f| f + f.basename('.*') } || [] libs += file_accessors.flat_map(&:vendored_static_libraries) @vendored_libraries = libs.compact.map(&:to_s) - puts "Final vendored libraries: #{@vendored_libraries}" + puts "Vendored libraries: #{@vendored_libraries}" @vendored_libraries end