[MacPorts] #21444: boost with +python26 links against wrong python on Snow Leopard
MacPorts
noreply at macports.org
Sun Oct 4 11:56:59 PDT 2009
#21444: boost with +python26 links against wrong python on Snow Leopard
---------------------------------+------------------------------------------
Reporter: stromnov@… | Owner: nox@…
Type: defect | Status: closed
Priority: Normal | Milestone:
Component: ports | Version: 1.8.0
Resolution: worksforme | Keywords:
Port: boost |
---------------------------------+------------------------------------------
Comment(by stromnov@…):
1. python2.6 framework broken in macports (please, read #21824)
2. we need explicitly pass -F${prefix}/Library/Frameworks to compiler for
proper linking with macport frameworks (as mentioned earlier by dbsgeo@)
3. linking must be done against framework or library, but (preferably)
not against both at the same time:
Compiling:
{{{
stromnov at stromnov:~$ gcc -Z -F/opt/local/Library/Frameworks
`python2.6-config --cflags` `python2.6-config --ldflags` -framework Python
test.c
stromnov at stromnov:~$ otool -L a.out a.out:
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
version 124.1.1)
/System/Library/Frameworks/Python.framework/Versions/2.6/Python
(compatibility version 2.6.0, current version 2.6.1)
/opt/local/Library/Frameworks/Python.framework/Versions/2.6/Python
(compatibility version 2.6.0, current version 2.6.0)
}}}
Double link (to system and macports pythons) caused by -lpython2.6 in
`python2.6-config --ldflags` and absence of -L/opt/local/lib in args.
{{{
stromnov at stromnov:~$ gcc -Z -F/opt/local/Library/Frameworks
-L/opt/local/lib `python2.6-config --cflags` `python2.6-config --ldflags`
-framework Python test.c
stromnov at stromnov:~$ otool -L a.out a.out:
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
version 124.1.1)
/opt/local/Library/Frameworks/Python.framework/Versions/2.6/Python
(compatibility version 2.6.0, current version 2.6.0)
}}}
--
Ticket URL: <http://trac.macports.org/ticket/21444#comment:25>
MacPorts <http://www.macports.org/>
Ports system for Mac OS
More information about the macports-tickets
mailing list