Question

I'm using Xcode 4.3.3. My project has 2 targets and they are very similar (one was a duplicate of the other). The only thing is they have different names and there is a small amount of #ifdef going on. One project compiles a few more files and copies a few more bundle resources than the other. Other than that they ought to be the same. It's like having Pro and Lite app versions.

I seem to have a few issues (building for one of the targets is absolutely fine, so all these issues relate to the 'other' target)...

  1. When building the 'other' target it gives me the warning "Multiple build commands for output file...". It is referring to 'icon-72.png'. However, I've not only removed the second reference to that file (still got the warning), but I have also removed that file entirely and removed all references I could find for it, including deleting the icon from the Target Summary, ensuring the file doesn't exist in any project folder in Finder for this project, and also ensuring it's not listed in 'Copy Bundle Resources' in 'Build Phases'. The warning still appears.

  2. When building the 'other' target it doesn't give me the usual warnings. These warnings should exist in both builds at this time. I have checked what is being compiled and the files that should generate these warnings are included in both 'Compile Sources' in both targets' 'Build Phases'.

  3. Building the 'other' target gives me 'Failed'. However, in the Issue Navigator there is no explanation as to why it failed.

Incidentally, the 'other' target was the original one, not the new one.

Also, I have tried cleaning before each build attempt and have also restarted Xcode. I have recently restarted the computer too.

Any help or general pointing in the right direction would be greatly appreciated.

Atb.

EDIT....

I updated the project settings as prompted in the Issue Navigator to use LLDB. Now I don't get any warnings for either target, but the 'other' target still fails to build without reason.

Was it helpful?

Solution

Right. Well, it turns out that this was mostly the answer (check the last comment). I closed the actual Xcode window with my project in (cmd-W), then I went to File > Open and opened the project file from there (as opposed to opening it from the splash window or the recents list).

Now I can see the warnings and tell why the build is failing too. Phew!!

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top