Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

XCFramework issue, A library with the identifier "ios-armv7_arm64" already exists

While creating XCFramework, I'm getting the below-mentioned message on the terminal and xcframework is not getting generated A library with the identifier "ios-armv7_arm64" already exists.

This is the command that I'm running

xcodebuild -create-xcframework \
-framework ./archives/My-iOS.xcarchive/Products/Library/Frameworks/My.framework \
-framework ./archives/My-iOS-Simulator.xcarchive/Products/Library/Frameworks/My.framework \
-output My.xcframework

Is there anything that I'm missing?

like image 830
NoobDeveloper Avatar asked Nov 07 '22 05:11

NoobDeveloper


1 Answers

Updated my script with the below-mentioned script, now this particular problem is solved but facing other problems. Those who are facing this issue can try out the script and see if it works.

xcodebuild archive -scheme FrameworkName -destination="iOS" -archivePath /tmp/xcf/ios.xcarchive -derivedDataPath /tmp/iphoneos -sdk iphoneos SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES


xcodebuild archive -scheme FrameworkName -destination="iOS Simulator" -archivePath /tmp/xcf/iossimulator.xcarchive -derivedDataPath /tmp/iphoneos -sdk iphonesimulator SKIP_INSTALL=NO BUILD_LIBRARY_FOR_DISTRIBUTION=YES


xcodebuild -create-xcframework -framework /tmp/xcf/ios.xcarchive/Products/Library/Frameworks/FrameworkName.framework -framework /tmp/xcf/iossimulator.xcarchive/Products/Library/Frameworks/FrameworkName.framework -output FrameworkName.xcframework
like image 172
NoobDeveloper Avatar answered Nov 15 '22 05:11

NoobDeveloper