Jenkins recently reported another packing error:

Codesigning /Users/Shared/Jenkins/Home/workspace/***/build/DerivedData/Build/Intermediates.noindex/ArchiveIntermediates/***/Installa tionBuildProductsLocation/Applications/***.app/Frameworks/libswiftCoreMedia.dylib /usr/bin/codesign --force --sign 2A252DD1931364B8ED615013655551EEF4C66515 --verbose /Users/Shared/Jenkins/Home/workspace/***/***/build/DerivedData/Build/Intermediates.noindex/ArchiveIntermediates/***/Inst allationBuildProductsLocation/Applications/***.app/Frameworks/libswiftCoreMedia.dylib /Users/Shared/Jenkins/Home/workspace/***/***/build/DerivedData/Build/Intermediates.noindex/ArchiveIntermediates/***/Inst allationBuildProductsLocation/Applications/***.app/Frameworks/libswiftCoreMedia.dylib: errSecInternalComponent error: Failed withexitcode 1 ** ARCHIVE FAILED ** The following build commands failed: CopySwiftLibs /Users/Shared/Jenkins/Home/workspace/***/***/build/DerivedData/Build/Intermediates.noindex/ArchiveIntermediates/***/Inst allationBuildProductsLocation/Applications/***.app (1 failure)Copy the code

The reason is that the server certificate did not exist, and then created a new one, but after importing it, an error was reported.

According to the website:

The errSecInternalComponent appears to be a bug with the Code signing mechanism in Xcode, where the number of accounts in xcode is large enough to generate a lot of outdated PP files. Xcode’s lack of built-in deletion will lead to repeated provisioning Profile imports. Solutions:

All the PP file, in the Xcode in ~ / Library/MobileDevice/Provisioning Profiles the folder; Enter the folder and delete the unnecessary ones. Re-import the new Provisioning Profile

2. Restart the Mac

However, after doing so, it does not work and still reports an error.

And finally referring to this,

Open the cli terminal, go to the project root directory, and run xattr -rc. Also can’t delete the following projects: / Users/Denny/Library/Developer/Xcode/DerivedData /

Reference: stackoverflow.com/questions/2…

Xattr-rc. deletes the extended attributes of a file.

I deleted the certificate, re-imported it, and changed the trust Settings of the certificate.

Github.com/fastlane/fa…