I want to add a static library to iOS.
first of all, I added some_library.a
file to ios/lib
directory, then I add vendored_libraries
to .podspec
file like this:
...
s.pod_target_xcconfig = { 'DEFINES_MODULE' => 'YES', 'EXCLUDED_ARCHS[sdk=iphonesimulator*]' => 'i386' }
s.swift_version = '5.0'
s.ios.vendored_libraries = 'lib/some_library.a'
end
but I get this error:
Xcode build done. 7.4s
Failed to build iOS app
Error output from Xcode build:
↳
** BUILD FAILED **
Xcode's output:
↳
ld: library not found for -lsome_library
clang: error: linker command failed with exit code 1 (use -v to see invocation)
note: Using new build system
note: Building targets in parallel
note: Planning build
note: Analyzing workspace
note: Constructing build description
note: Build preparation complete
Could not build the application for the simulator.
Error launching application on iPhone 12 Pro Max.
Does anyone know what is the issue?