Re: Problem connecting to Oracle with app run from XCode
Re: Problem connecting to Oracle with app run from XCode
- Subject: Re: Problem connecting to Oracle with app run from XCode
- From: Timothy Mowlem <email@hidden>
- Date: Fri, 8 Oct 2010 23:20:22 +0100
> Greg Guerin wrote:
>> Timothy Mowlem wrote:
>>
>> I can run the XCode built app as well from the command line after
>> setting LD_LIBRARY_PATH (as a non-admin user and without using sudo).
> If that env-var is the cause, then printf() the value of it in both
> cases, and manually compare them. Use the getenv() C function.
>
> You might also read the Mac OS X man page for 'dyld', if you haven't
> done so yet.
> Xcode > Help > Open man Page...
>
> -- GG
Thanks for the input. I might have been slightly misleading but I think LD_LIBRARY_PATH is fine. For a while I was getting a link error at runtime until I read the XCode documentation and found the correct place to set the env var to run it within XCode, by selecting the executable under the Executables group, choosing GetInfo and adding the env var under the environment area of the Arguments tab.
I confirmed that it is finding and using the library using printfs.
I have also discovered that if I start XCode from the terminal, which means it WILL pick up the environment from the shell, that the application DOES then run successfully when launched from XCode. So the conclusion is that something in my shell environment that is not present in XCode when it is launched normally is causing the problem.
Has anyone seen anything similar?
Thanks.
Tim_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden