Re: [capi-sig] Linking problem

On 24.02.2013 14:55, ecir hana wrote:
On Sun, Feb 24, 2013 at 2:30 PM, M.-A. Lemburg <mal@egenix.com> wrote:
Something is wrong here: the library is usually called something like "libpython3.3m.a".
There was "libpython3.3.dylib" which is a symlink to "Python" which I renamed to "python33" so it does not collide with installed "Python" v2.7. I also tried "python33.dylib", "libpython33", "libpython33.dylib", "libpython33.so" to no avail...
Sorry, I can't help with the versions from the Python installer on python.org. Both the Apple provided and the python.org versions have given us too much trouble in the past. We're always compiling our own versions, try to avoid fat binaries and use default settings when compiling Python.
Btw, why ".a"? I thought that for static linking. The binary distribution from python.org only contains some dylibs...
The .a libs are indeed for static linking. You can try to use dylibs for your application, but chances are high that your users will run into problems picking up a dylib from one of the many sources for this file (Apple's Python lib, python.org installer, MacPorts, Homebrew, Fink, etc.). Each of those will likely have been compiled using slightly different settings or even come with internal changes.
You can avoid all that by doing static linking.
Please make sure that you actually have the correct library in
your current directory.
I think I have - it just those 3 files from above in the directory.
"gcc -lname" will look for a file libname.a or libname.dylib. Please see the man page for details.
-- Marc-Andre Lemburg eGenix.com
Professional Python Services directly from the Source (#1, Feb 24 2013)
Python Projects, Consulting and Support ... http://www.egenix.com/ mxODBC.Zope/Plone.Database.Adapter ... http://zope.egenix.com/ mxODBC, mxDateTime, mxTextTools ... http://python.egenix.com/
::::: Try our mxODBC.Connect Python Database Interface for free ! ::::::
eGenix.com Software, Skills and Services GmbH Pastor-Loeh-Str.48 D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg Registered at Amtsgericht Duesseldorf: HRB 46611 http://www.egenix.com/company/contact/

On Sun, Feb 24, 2013 at 3:10 PM, M.-A. Lemburg <mal@egenix.com> wrote:
You can try to use dylibs
for your application, but chances are high that your users will run into problems picking up a dylib from one of the many sources for this file
I thought that if I include the dynamic library into the application bundle it should pick the version I provide..?
"gcc -lname" will look for a file libname.a or libname.dylib. Please see the man page for details.
That's exactly the problem, The folder has "libpython33.dylib" file but when I do "gcc -lname libpython33" it says "i686-apple-darwin11-llvm-gcc-4.2: libpython33: No such file or directory".
participants (2)
-
ecir hana
-
M.-A. Lemburg