Xcode doesn't run application correctly

D

dr_springfield

Guest
Hey,
Two questions:
1) Xcode started to not run my app correctly. It builds fine, and it run fine if I run the application directly from the finder, out of the build directory. But for some reason, when I try to run the app or debug the app through xcode, strange things happen. First, the application's icon doesn't appear in the dock, like it normally does. It starts up in the background, and I can't switch to it. If I try to click on it, it doesn't become active. The only click that works on it is to press the close button on the window. Xcode works properly for other applications I'm working on. It used to work fine for this one, but one day it stopped working -- this might be a configuration problem.

2) When I changed the name of my project directory, I got an error: path/libstdc++_ZeroLink.dylib (No such file or directory, errno = 2)
The problem was that the path to this library had changed when I changed the directory name. I had to change it back to get it to work. How do I make the path to this library dynamic, or just change it at all?

Thanks a lot for any help.
 
Joined
Mar 9, 2004
Messages
2,860
Reaction score
21
Points
38
Location
Miami FL
Your Mac's Specs
G4 1Ghz OS X 10.4.7
Some apps will run rightly only from the Finder > Applications directory. :rolleyes: I guess it's about having only some directories as application paths Does that help?
 
OP
D

dr_springfield

Guest
I finally solved this problem and the solution was almost too ridiculous to post. The problem was, believe it or not, the difference in the case of only two characters of the CFBundleName of the application in the Info.plist file. If you change it, your app won't run correctly thru Xcode (at least for me), so I wouldn't recommend touching it. I think it's because there was a case-sensitive difference between the name of the project which Xcode had stored somewhere else, and the CFBundleName.
 

rman


Retired Staff
Joined
Dec 24, 2002
Messages
12,637
Reaction score
168
Points
63
Location
Los Angeles, California
Your Mac's Specs
14in MacBook Pro M1 Max 32GB 2TB
You learned a very valuable lesson. Unix is case sensitive, when you are working in the command line (terminal). :D
 
OP
D

dr_springfield

Guest
A correction: the problem with case sensitivity was in CFBundleExecutable, not CFBundleName (the former is defined in Info.plist, the latter in InfoPlist.strings). I thought this is a bug in Xcode, because the app will run fine from the finder, however the same thing happened when trying to run the app thru gdb from the terminal.
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top