Attempting to recomple an old OS X screensaver in 10.8. Xcode reports Cocoa/Cocoa.h "file not found"

StackOverflow https://stackoverflow.com/questions/22110769

  •  18-10-2022
  •  | 
  •  

Question

When I compile in Xcode 4.6.1, I am getting an error stating Cocoa/Cocoa.h "file not found" I have tried troubleshooting this in the past, but ended up not being able to figure out what to do, or if this is even possible. Anyone have any ideas? On what / where I should look? What to do next?

The program I am attempting to compile is a screen saver from http://www.spiderland.org/breve/download.php called breve creatures. It used to work back in the 10.4.x days. Hence me adding a legacy tag to this post. I can provide more details if you need them, I just don't know what is important information at this point.

No correct solution

OTHER TIPS

It's possible your project is not linking against the current version of the Cocoa framework, but is instead linking against the Cocoa framework from a specific SDK version (such as OS X 10.4), which may be missing from your current system.

In Xcode, choose your build target and select Build Phases. Expand "Link Binary with Libraries" and ensure that Cocoa is listed. You may need to remove it and re-add it to this list. When you press the + button to add a framework to link, ensure you are choosing Cocoa from the correct SDK folder. (I don't know what is installed on your system or whether you want to support OS X systems earlier than 10.8.) Add the framework, clean the project, and build again.

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