codesign failed: resource fork, Finder information, or similar detritus not allowed

After updating AdscendMedia SDK in one of our app, when building the app, stumbled upon this error:

<project_folder>/Frameworks/AdscendMedia.framework: replacing existing signature
<project_folder>/Frameworks/AdscendMedia.framework: resource fork, Finder information, or similar detritus not allowed
Command /usr/bin/codesign failed with exit code 1

Found the solution here: https://developer.apple.com/library/content/qa/qa1940/_index.html

First, find files inside SDK framework folder which have extended attribute containing resource fork or Finder info:

cd <project_folder>/Frameworks
xattr -lr AdscendMedia.framework/

If got files, then delete them:

xattr -cr AdscendMedia.framework/

Leave a Reply

Your email address will not be published. Required fields are marked *