Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

iOS: Codesign error: bundle format unrecognized, invalid, or unsuitable in subcomponent Base.lproj

I have a project that was building just fine. Seemingly randomly, doing a Run one time resulted in a codesign error that I've been unable to resolve for 2 days.

The error reads:

bundle format unrecognized, invalid, or unsuitable In subcomponent: /Users/user/Library/Developer/Xcode/DerivedData/.../Base.lproj

I'm not sure why this error sprung up. It may have happened after I selected a 'Team' in Xcode - but I can't remember (and I don't know why that would cause an issue). I tried cleaning up my Keychain, creating the bundle identifier in my developer account, a handful of Terminal commands from other posts, to no avail.

What's odd to me is that it seems to indicate it has something to do with Base.lproj - which holds only the LaunchScreen nib and my Main.storyboard. Could there be something in Storyboard that is causing a codesign issue? Something else? SOS.

like image 397
H K Avatar asked Jan 30 '15 07:01

H K


3 Answers

This is a big stab in the dark, but I got this error when I added a directory named "resources". Removing it fixed the issue for me.

like image 161
Jacob Mouka Avatar answered Sep 28 '22 04:09

Jacob Mouka


I ran into the same issue with Xcode 7.3.1 and cocoapods. I ended up doing the following:

1.Closed Xcode

2.Removed everything under my DerivedData folder

rm -fr /Users/{user}/Library/Developer/Xcode/DerivedData/*

3.Restarted Xcode and rebuilt the project

like image 41
Kunal Arora Avatar answered Sep 28 '22 05:09

Kunal Arora


I got this error when I added the script fixing a keychain error -34018 which first had appeared in XCode 6.3.

#!/bin/sh
codesign --verify --force --sign "$CODE_SIGN_IDENTITY" 
"$CODESIGNING_FOLDER_PATH"
like image 42
Vladimír Slavík Avatar answered Sep 28 '22 04:09

Vladimír Slavík