I'm doing an evaluation of SQL Anywhere 12 for my company. We want to use the db as a datastore behind an application using the c api to access the database. In the last couple of days I've managed to get a sample application to run on windows and 11.10 ubuntu but I can't get the same application to run on mac osx 7.
I've created a small project in Xcode 4, added the sample code and it all compiles fine.
When I run the app however I get:
Failed to load library: dlopen(libdbcapi_r.dylib, 1): image not found Could not initialize the interface!
Can anybody tell me how I setup the dynamic libraries within the Xcode project so they're available to the application at runtime?
Failing that, do I have to make a copy of the dylibs and run the install_name_tool against them to generate install names that I then use to reference them?
I'm very new to Mac programming so any help would be appreciated.
Turns out that even after setting up the environment variables in ./MacOSX/environment.plist, Xcode 4 overrides the
You have to set the environment variables explicitly in the scheme of the application to have them available when debugging.
Having done that I can now connect successfully to a running db server.
answered 06 Jan '12, 18:20