I'm trying to build my app using xcodebuild
command in the terminal. It's failing to do so however, and giving me this error:
CodeSign build/Release-iphoneos/frameworkname.framework
cd /path/frameworkname
export CODESIGN_ALLOCATE=/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/git/bin"
Signing Identity: "my signing identity"
Provisioning Profile: "provisioning profile"
(numbersandletters)
/usr/bin/codesign --force --sign numbersandletters /path/frameworkname/build/Release-iphoneos/frameworkname.framework
/path/frameworkname/build/Release-iphoneos/frameworkname.framework: bundle format unrecognized, invalid, or unsuitable
Command /usr/bin/codesign failed with exit code 1
** BUILD FAILED **
The following build commands failed:
CodeSign build/Release-iphoneos/frameworkname.framework
(1 failure)
I'm using this command, while inside the project folder:
xcodebuild -target myprojectname -sdk iphoneos -configuration Release
Also tried adding -project myprojectname.xcodeproj
but that doesn't make a difference, I still ge the same error.
I tried the script that was posted here but that didn't work for me either. I think it's because I don't have a Versions folder in my framework. That might be a place to start, but I don't know what to do tbh. Any help would be much appreciated :)
We found a solution that would build our project. We used this command
xcodebuild -project testerProject.xcodeproj -sdk iphoneos -configuration Release clean build RUN_CLANG_STATIC_ANALYZER=NO -scheme testerProject archive