@@ -277,16 +277,20 @@ def static_libs_in_sandbox(build_dir = 'build')
277
277
278
278
def vendored_libraries
279
279
if @vendored_libraries
280
- @vendored_libraries
280
+ return @vendored_libraries
281
281
end
282
282
file_accessors = if @exclude_deps
283
+ puts "Excluding dependencies"
283
284
@file_accessors
284
285
else
286
+ puts "Including dependencies"
285
287
@static_installer . pod_targets . flat_map ( &:file_accessors )
286
288
end
287
289
libs = file_accessors . flat_map ( &:vendored_static_frameworks ) . map { |f | f + f . basename ( '.*' ) } || [ ]
288
290
libs += file_accessors . flat_map ( &:vendored_static_libraries )
289
291
@vendored_libraries = libs . compact . map ( &:to_s )
292
+ puts "Final vendored libraries: #{ @vendored_libraries } "
293
+
290
294
@vendored_libraries
291
295
end
292
296
@@ -304,10 +308,28 @@ def ios_build_options
304
308
end
305
309
306
310
def ios_architectures
307
- archs = %w( x86_64 i386 arm64 armv7 armv7s )
311
+ xcode_version_string = `xcodebuild -version` . strip . split ( ) [ 1 ]
312
+ xcode_version = Pod ::Version . new ( xcode_version_string )
313
+ UI . puts "current xcode version: #{ xcode_version } "
314
+ archs = if xcode_version >= Pod ::Version . new ( '14.0' )
315
+ # i386 & armv7/armv7s has been deprecated in Xcode14
316
+ %w( x86_64 arm64 arm64e )
317
+ elsif xcode_version < Pod ::Version . new ( '10.0' )
318
+ %w( x86_64 i386 arm64 armv7 armv7s )
319
+ else
320
+ %w( x86_64 i386 arm64 arm64e armv7 armv7s )
321
+ end
322
+ UI . puts "Initial architectures: #{ archs } "
323
+
308
324
vendored_libraries . each do |library |
309
- archs = `lipo -info #{ library } ` . split & archs
325
+ library_archs = `lipo -info #{ library } ` . split
326
+ UI . puts "Architectures for #{ library } : #{ library_archs } "
327
+
328
+ archs = library_archs & archs
329
+ UI . puts "Intersected architectures: #{ archs } "
310
330
end
331
+
332
+ UI . puts "Final architectures: #{ archs } "
311
333
archs
312
334
end
313
335
0 commit comments