Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error when building the project in Xcode

I get following error while building the project.

Clening also didn't help. No idea what went wrong all of a sudden

CompileAssetCatalog /Users/Mayu/Library/Developer/Xcode/DerivedData/Pizza_to_Go-dohdzfdfbyycqrhirbysuinqfuzf/Build/Products/Debug-iphonesimulator/Pizza\ to\ Go.app Pizza\ to\ Go/Images.xcassets Pizza\ to\ Go/Images.xcassets
    cd "/Users/Mayu/Documents/development/git/pizzatogo/iPhoneApp/Pizza to Go"
    setenv PATH "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
    /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/actool --output-format human-readable-text --notices --warnings --export-dependency-info /Users/Mayu/Library/Developer/Xcode/DerivedData/Pizza_to_Go-dohdzfdfbyycqrhirbysuinqfuzf/Build/Intermediates/Pizza\ to\ Go.build/Debug-iphonesimulator/Pizza\ to\ Go.build/assetcatalog_dependencies.txt --output-partial-info-plist /Users/Mayu/Library/Developer/Xcode/DerivedData/Pizza_to_Go-dohdzfdfbyycqrhirbysuinqfuzf/Build/Intermediates/Pizza\ to\ Go.build/Debug-iphonesimulator/Pizza\ to\ Go.build/assetcatalog_generated_info.plist --app-icon AppIcon --launch-image LaunchImage --platform iphonesimulator --minimum-deployment-target 7.0 --target-device iphone --compress-pngs --compile /Users/Mayu/Library/Developer/Xcode/DerivedData/Pizza_to_Go-dohdzfdfbyycqrhirbysuinqfuzf/Build/Products/Debug-iphonesimulator/Pizza\ to\ Go.app /Users/Mayu/Documents/development/git/pizzatogo/iPhoneApp/Pizza\ to\ Go/Pizza\ to\ Go/Images.xcassets /Users/Mayu/Documents/development/git/pizzatogo/iPhoneApp/Pizza\ to\ Go/Pizza\ to\ Go/Images.xcassets

/* com.apple.actool.errors */
: error: There are multiple app icon set instances named "AppIcon".
: error: There are multiple launch image set instances named "LaunchImage".
/* com.apple.actool.compilation-results */
/Users/Mayu/Library/Developer/Xcode/DerivedData/Pizza_to_Go-dohdzfdfbyycqrhirbysuinqfuzf/Build/Products/Debug-iphonesimulator/Pizza to Go.app/Assets.car
/Users/Mayu/Library/Developer/Xcode/DerivedData/Pizza_to_Go-dohdzfdfbyycqrhirbysuinqfuzf/Build/Intermediates/Pizza to Go.build/Debug-iphonesimulator/Pizza to Go.build/assetcatalog_generated_info.plist
like image 529
Jay Mayu Avatar asked Dec 13 '13 09:12

Jay Mayu


People also ask

Why is my build failing in Xcode?

A common cause of failing builds is that Xcode Cloud can't access the Package. resolved file that it needs to resolve your Swift Package dependencies. To resolve issues related to the Package.

How do I fix Xcode errors?

Conversation. Xcode tip #5: If you have a Swift file with many errors, you can use Xcode's fix-its to try to correct them one by one. But a faster way is to go to the Editor menu and choose Fix All Issues to apply fix-its all at once. (Make sure and double-check which changes were made!)

How do I clean up and build in Xcode?

Clean the Build Folder To clean the build folder you can use the shortcut Command+Option+Shift+K or Menu Bar → Product → Hold Option Key → Clean build Folder .

Can not open project in Xcode?

Quit Xcode, then make a copy of the xcworkspace file (just in case). In finder, right-click the xcworkspace file and choose Show File Contents. In that directory, open the xcuserdata directory and delete any contents. Start Xcode again and open the project.


2 Answers

As this error says you have duplicated images AppIcon and LaunchImage. To sort it just make copy of it and remove it from your project (have a look in Images.xcassets and remove it as well). After that import it again to Images.xcassets.

like image 125
Greg Avatar answered Oct 27 '22 21:10

Greg


For me, the problem was that I had my assets folder with multiple targets with while extensions already had those target assigned. Fix was to make sure each asset folder was only assigned to its specific target, or delete folders that are not needed.

enter image description here

like image 4
Andy Avatar answered Oct 27 '22 20:10

Andy