I had similar symptoms with my OSX Lion machine and macports-built dependencies. In my case, I was using the macports Python 2.6, but pmt_swig.so was linked against the OSX-provided Python 2.7 library, unlike everything else which was properly linked against the /opt/local macports python 2.6.

The cmake command line that got it working for me was:
cmake .. -DPYTHON_LIBRARY=/opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/config/libpython2.6.dylib -DPYTHON_INCLUDE_DIR=/opt/local/Library/Frameworks/Python.framework/Versions/2.6/include/python2.6

In that case I'm not specifying the python executable because the proper one was first in the path. I don't know if this is exactly your problem, but it's definitely worth thinking through the library deps to make sure you are not mixing python installations up.

In your case I am suspicious of the "/System/Library/Frameworks/Python.framework/Versions/2.7/Python" dependency when everything else is pointing to /opt/local.

-Peter

On 02/11/2012 06:12 PM, Daniel O'Connor wrote:
Hi,
I'm trying to build and run GNURadio on OSX Lion (with MacPorts) but I am 
having trouble with UHD.

I've built and install GNURadio (from git) however when I run anything the 
Python interpreter crashes like so..
In [1]: import gnuradio.uhd
Mac OS; GNU C++ version 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 
2335.15.00); Boost_104800; UHD_003.004.000-122b947

Fatal Python error: Interpreter not initialized (version mismatch?)

Since I initially got UHD as a binary I uninstalled it then built it from the 
sources but I get the same problem.

Running 'ccmake' shows the Python path as /opt/local/bin as I expect.

The stack trace and binary image list look like so..
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   libsystem_kernel.dylib              0x00007fff8bd5982a __kill + 10
1   libsystem_c.dylib                   0x00007fff892b6a9c abort + 177
2   org.python.python                   0x00000001035b196e Py_FatalError + 49
3   org.python.python                   0x00000001035af46b Py_InitModule4_64 + 
74
4   _uhd_swig.so                        0x0000000103472b8f init_uhd_swig + 543
5   org.python.python                   0x0000000102fce1aa 
_PyImport_LoadDynamicModule + 170
6   org.python.python                   0x0000000102fcaae5 imp_load_module + 341
7   org.python.python                   0x0000000102fb4a7b PyEval_EvalFrameEx + 
18011
8   org.python.python                   0x0000000102fb7e13 fast_function + 179
9   org.python.python                   0x0000000102fb4b2d PyEval_EvalFrameEx + 
18189
10  org.python.python                   0x0000000102fb7cd7 PyEval_EvalCodeEx + 
2103
11  org.python.python                   0x0000000102fb7d56 PyEval_EvalCode + 54
12  org.python.python                   0x0000000102fcb123 
PyImport_ExecCodeModuleEx + 243
13  org.python.python                   0x0000000102fcb796 load_source_module + 
1462
14  org.python.python                   0x0000000102fcc763 import_submodule + 
467
15  org.python.python                   0x0000000102fcc97b load_next + 251
16  org.python.python                   0x0000000102fcd7d0 
PyImport_ImportModuleLevel + 1184
17  org.python.python                   0x0000000102faadf4 builtin___import__ + 
132
18  org.python.python                   0x0000000102f1cae1 PyObject_Call + 97
19  org.python.python                   0x0000000102faf824 
PyEval_CallObjectWithKeywords + 180
20  org.python.python                   0x0000000102fb6746 PyEval_EvalFrameEx + 
25382
21  org.python.python                   0x0000000102fb7cd7 PyEval_EvalCodeEx + 
2103
22  org.python.python                   0x0000000102fb7e88 fast_function + 296
23  org.python.python                   0x0000000102fb4b2d PyEval_EvalFrameEx + 
18189
24  org.python.python                   0x0000000102fb7cd7 PyEval_EvalCodeEx + 
2103
25  org.python.python                   0x0000000102fb7d56 PyEval_EvalCode + 54
26  org.python.python                   0x0000000102fcb123 
PyImport_ExecCodeModuleEx + 243
27  org.python.python                   0x0000000102fcb796 load_source_module + 
1462
28  org.python.python                   0x0000000102fcc155 load_package + 357
29  org.python.python                   0x0000000102fcc763 import_submodule + 
467
30  org.python.python                   0x0000000102fcc97b load_next + 251
31  org.python.python                   0x0000000102fcd815 
PyImport_ImportModuleLevel + 1253
32  org.python.python                   0x0000000102faadf4 builtin___import__ + 
132
33  org.python.python                   0x0000000102f1cae1 PyObject_Call + 97
34  org.python.python                   0x0000000102faf824 
PyEval_CallObjectWithKeywords + 180
35  org.python.python                   0x0000000102fb6746 PyEval_EvalFrameEx + 
25382
36  org.python.python                   0x0000000102fb7cd7 PyEval_EvalCodeEx + 
2103
37  org.python.python                   0x0000000102fb7d56 PyEval_EvalCode + 54
38  org.python.python                   0x0000000102fd7ca2 
PyRun_InteractiveOneFlags + 578
39  org.python.python                   0x0000000102fd7dfe 
PyRun_InteractiveLoopFlags + 222
40  org.python.python                   0x0000000102fd7ea7 PyRun_AnyFileExFlags 
+ 119
41  org.python.python                   0x0000000102fea919 Py_Main + 2969
42  org.python.python                   0x0000000102f0af14 0x102f0a000 + 3860

Thread 0 crashed with X86 Thread State (64-bit):
   rax: 0x0000000000000000  rbx: 0x00007fff62b06430  rcx: 0x00007fff62b06418  
rdx: 0x0000000000000000
   rdi: 0x0000000000006cfe  rsi: 0x0000000000000006  rbp: 0x00007fff62b06440  
rsp: 0x00007fff62b06418
    r8: 0x00000000000003f5   r9: 0x00007fff62b06438  r10: 0x00007fff8bd5ae62  
r11: 0xffffff80002d8220
   r12: 0x00000001034d2212  r13: 0x0000000000000000  r14: 0x0000000000000000  
r15: 0x00000001034e9420
   rip: 0x00007fff8bd5982a  rfl: 0x0000000000000202  cr2: 0x00000001035ef464
Logical CPU: 0

Binary Images:
        0x102f0a000 -        0x102f0aff7 +org.python.python (2.7.2 - 
2.7.2)<C0821441-9843-3091-A2C7-E8E991BCEC65>  
/opt/local/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python
        0x102f13000 -        0x103054fef +org.python.python (2.7.2, [c] 2004-2011 
Python Software Foundation. - 2.7.2)<38D08105-FB64-390C-9187-7920DE495553>  
/opt/local/Library/Frameworks/Python.framework/Versions/2.7/Python
        0x103286000 -        0x1032c3fff +readline.so (??? - 
???)<4A8FB72E-7160-3FD8-B6C9-2CADAB9787EA>  
/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/readline/readline.so
        0x1032de000 -        0x10331dfef +libncurses.5.dylib (5.0.0 - compatibility 
5.0.0)<9FC5E997-7C15-3B1A-9953-8C1F2624ED31>  /opt/local/lib/libncurses.5.dylib
        0x103400000 -        0x1034e3fff +_uhd_swig.so (??? - 
???)<2D31B6D9-420D-3FBB-9310-21A97E1442FA>  
/usr/local/lib/python2.7/site-packages/gnuradio/uhd/_uhd_swig.so
        0x103510000 -        0x10362bff7  org.python.python (2.7.1 - 
2.7.1)<A7E34EB5-24D2-3B8F-A26B-4A5B28CD2C60>  
/System/Library/Frameworks/Python.framework/Versions/2.7/Python
        0x103690000 -        0x1036acfff +libgnuradio-uhd.3.5.2git.dylib (??? - 
???)<D5F6FAEB-F6F3-3F19-92FB-CA07AF96EFCD>  
/usr/local/lib/libgnuradio-uhd.3.5.2git.dylib
        0x1036c0000 -        0x103965ff7 +libuhd.003.dylib (3.4.0 - compatibility 
3.0.0)<57F18B76-810C-3B34-AA8A-1FA0BBB6877C>  /usr/local/lib/libuhd.003.dylib
        0x103a5e000 -        0x103beafef +libgnuradio-core.3.5.2git.dylib (??? - 
???)<54C1700A-CF6B-389F-86E5-025BF29D5D04>  
/usr/local/lib/libgnuradio-core.3.5.2git.dylib
        0x103c97000 -        0x103cd2ff7 +libgruel.3.5.2git.dylib (??? - 
???)<61ACA8BD-1141-3D83-9401-BBE530AB1C99>  
/usr/local/lib/libgruel.3.5.2git.dylib
        0x103cf1000 -        0x103cf8ff7 +libboost_date_time-mt.dylib (??? - 
???)<F9D6479D-2019-34EA-B411-D362AA76D8F9>  
/opt/local/lib/libboost_date_time-mt.dylib
        0x103d0e000 -        0x103d45fff +libboost_program_options-mt.dylib (??? - 
???)<4C667CDB-3DFD-3464-98CE-9FFAD309DF03>  
/opt/local/lib/libboost_program_options-mt.dylib
        0x103da2000 -        0x103db6ff7 +libboost_filesystem-mt.dylib (??? - 
???)<40946367-511F-3055-9935-C2A92A43FED8>  
/opt/local/lib/libboost_filesystem-mt.dylib
        0x103dd3000 -        0x103dd7fff +libboost_system-mt.dylib (??? - 
???)<8D4D3BAD-265C-38C9-A5FA-3C8BC26E205D>  
/opt/local/lib/libboost_system-mt.dylib
        0x103ddc000 -        0x103dedff7 +libboost_thread-mt.dylib (??? - 
???)<3556F4D9-FE25-30E3-B1DC-672A5FA8C295>  
/opt/local/lib/libboost_thread-mt.dylib
        0x103e0f000 -        0x103fc3fef +libgsl.0.dylib (17.0.0 - compatibility 
17.0.0)<864FD2D5-D4DA-3D83-A44F-9F54B0920D25>  /opt/local/lib/libgsl.0.dylib
        0x104020000 -        0x104056fff +libgslcblas.0.dylib (??? - 
???)<2A099779-2959-317C-A2A5-2FD9B59F0B26>  /opt/local/lib/libgslcblas.0.dylib
        0x10405a000 -        0x104200ff7 +libfftw3f.3.dylib (7.0.0 - compatibility 
7.0.0)<8A76D9D5-D593-3795-BC44-AB36522BF225>  /opt/local/lib/libfftw3f.3.dylib
        0x104223000 -        0x104226fff +libfftw3f_threads.3.dylib (7.0.0 - 
compatibility 7.0.0)<A898C20C-9ECA-377E-A71D-F8FBC8308FE1>  
/opt/local/lib/libfftw3f_threads.3.dylib
        0x10422a000 -        0x1042f3fe7 +libboost_regex-mt.dylib (??? - 
???)<411E9326-49A0-309C-9669-8BBC31242190>  
/opt/local/lib/libboost_regex-mt.dylib
        0x1043b9000 -        0x104421fff +libboost_unit_test_framework-mt.dylib (??? 
- ???)<CAC59DD3-8311-3069-B539-A79AE2EA0C39>  
/opt/local/lib/libboost_unit_test_framework-mt.dylib
        0x104503000 -        0x104571fff +liborc-0.4.0.dylib (17.0.0 - compatibility 
17.0.0)<A2FA9747-E999-321D-B461-7EED2835654F>  /opt/local/lib/liborc-0.4.0.dylib
        0x10458a000 -        0x1046a8ff7 +libicuuc.48.dylib (48.1.0 - compatibility 
48.0.0)<5DF8A2F8-1C31-3BFF-A8A4-8A75C5E8B1E6>  /opt/local/lib/libicuuc.48.dylib
        0x104703000 -        0x10488ffef +libicui18n.48.dylib (48.1.0 - compatibility 
48.0.0)<89D2AE9E-0CD3-3FC6-8DF3-D59F493854C8>  
/opt/local/lib/libicui18n.48.dylib
        0x10492d000 -        0x105a9afff +libicudata.48.dylib (48.1.0 - compatibility 
48.0.0)<0FF5FE6A-3A61-3A33-9836-C4A4EAE30DD5>  
/opt/local/lib/libicudata.48.dylib
     0x7fff62b0a000 -     0x7fff62b3ebaf  dyld (195.6 - 
???)<0CD1B35B-A28F-32DA-B72E-452EAD609613>  /usr/lib/dyld
     0x7fff823c2000 -     0x7fff823dffff  libxpc.dylib (77.18.0 - compatibility 
1.0.0)<26C05F31-E809-3B47-AF42-1460971E3AC3>  /usr/lib/system/libxpc.dylib
     0x7fff82405000 -     0x7fff8240cfff  libcopyfile.dylib (85.1.0 - compatibility 
1.0.0)<172B1985-F24A-34E9-8D8B-A2403C9A0399>  /usr/lib/system/libcopyfile.dylib
     0x7fff82411000 -     0x7fff82416fff  libcompiler_rt.dylib (6.0.0 - compatibility 
1.0.0)<98ECD5F6-E85C-32A5-98CD-8911230CB66A>  
/usr/lib/system/libcompiler_rt.dylib
     0x7fff8249d000 -     0x7fff8249ffff  libquarantine.dylib (36.2.0 - compatibility 
1.0.0)<48656562-FF20-3B55-9F93-407ACA7341C0>  
/usr/lib/system/libquarantine.dylib
     0x7fff8266f000 -     0x7fff8267dfff  libdispatch.dylib (187.7.0 - compatibility 
1.0.0)<712AAEAC-AD90-37F7-B71F-293FF8AE8723>  /usr/lib/system/libdispatch.dylib
     0x7fff8342b000 -     0x7fff83431fff  libmacho.dylib (800.0.0 - compatibility 
1.0.0)<D86F63EC-D2BD-32E0-8955-08B5EAFAD2CC>  /usr/lib/system/libmacho.dylib
     0x7fff84cf2000 -     0x7fff84cf7fff  libcache.dylib (47.0.0 - compatibility 
1.0.0)<B7757E2E-5A7D-362E-AB71-785FE79E1527>  /usr/lib/system/libcache.dylib
     0x7fff85231000 -     0x7fff85239fff  libsystem_dnssd.dylib (??? - 
???)<7749128E-D0C5-3832-861C-BC9913F774FA>  
/usr/lib/system/libsystem_dnssd.dylib
     0x7fff87c29000 -     0x7fff87dfdfff  com.apple.CoreFoundation (6.7.1 - 
635.19)<57B77925-9065-38C9-A05B-02F4F9ED007C>  
/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
     0x7fff87e5d000 -     0x7fff87e5efff  libdnsinfo.dylib (395.6.0 - compatibility 
1.0.0)<718A135F-6349-354A-85D5-430B128EFD57>  /usr/lib/system/libdnsinfo.dylib
     0x7fff87ff5000 -     0x7fff8806aff7  libc++.1.dylib (19.0.0 - compatibility 
1.0.0)<C0EFFF1B-0FEB-3F99-BE54-506B35B555A9>  /usr/lib/libc++.1.dylib
     0x7fff88134000 -     0x7fff8813aff7  libunwind.dylib (30.0.0 - compatibility 
1.0.0)<1E9C6C8C-CBE8-3F4B-A5B5-E03E3AB53231>  /usr/lib/system/libunwind.dylib
     0x7fff8813b000 -     0x7fff8813ffff  libdyld.dylib (195.5.0 - compatibility 
1.0.0)<F1903B7A-D3FF-3390-909A-B24E09BAD1A5>  /usr/lib/system/libdyld.dylib
     0x7fff88888000 -     0x7fff88892ff7  liblaunch.dylib (392.18.0 - compatibility 
1.0.0)<39EF04F2-7F0C-3435-B785-BF283727FFBD>  /usr/lib/system/liblaunch.dylib
     0x7fff89275000 -     0x7fff89352fef  libsystem_c.dylib (763.12.0 - compatibility 
1.0.0)<FF69F06E-0904-3C08-A5EF-536FAFFFDC22>  /usr/lib/system/libsystem_c.dylib
     0x7fff8941d000 -     0x7fff8941efff  libDiagnosticMessagesClient.dylib (??? - 
???)<3DCF577B-F126-302B-BCE2-4DB9A95B8598>  
/usr/lib/libDiagnosticMessagesClient.dylib
     0x7fff8941f000 -     0x7fff8941ffff  libkeymgr.dylib (23.0.0 - compatibility 
1.0.0)<61EFED6A-A407-301E-B454-CD18314F0075>  /usr/lib/system/libkeymgr.dylib
     0x7fff89437000 -     0x7fff894aafff  libstdc++.6.dylib (52.0.0 - compatibility 
7.0.0)<6BDD43E4-A4B1-379E-9ED5-8C713653DFF2>  /usr/lib/libstdc++.6.dylib
     0x7fff894d7000 -     0x7fff895bbe5f  libobjc.A.dylib (228.0.0 - compatibility 
1.0.0)<871E688B-CF57-3BC7-80D6-F6476DFF109B>  /usr/lib/libobjc.A.dylib
     0x7fff89c8e000 -     0x7fff89e90fff  libicucore.A.dylib (46.1.0 - compatibility 
1.0.0)<38CD6ED3-C8E4-3CCD-89AC-9C3198803101>  /usr/lib/libicucore.A.dylib
     0x7fff8a071000 -     0x7fff8a075fff  libmathCommon.A.dylib (2026.0.0 - 
compatibility 1.0.0)<FF83AFF7-42B2-306E-90AF-D539C51A4542>  
/usr/lib/system/libmathCommon.A.dylib
     0x7fff8a757000 -     0x7fff8a769ff7  libz.1.dylib (1.2.5 - compatibility 
1.0.0)<30CBEF15-4978-3DED-8629-7109880A19D4>  /usr/lib/libz.1.dylib
     0x7fff8b8de000 -     0x7fff8b8e3ff7  libsystem_network.dylib (??? - 
???)<5DE7024E-1D2D-34A2-80F4-08326331A75B>  
/usr/lib/system/libsystem_network.dylib
     0x7fff8b92c000 -     0x7fff8b959fe7  libSystem.B.dylib (159.1.0 - compatibility 
1.0.0)<095FDD3C-3961-3865-A59B-A5B0A4B8B923>  /usr/lib/libSystem.B.dylib
     0x7fff8bd43000 -     0x7fff8bd63fff  libsystem_kernel.dylib (1699.22.73 - 
compatibility 1.0.0)<69F2F501-72D8-3B3B-8357-F4418B3E1348>  
/usr/lib/system/libsystem_kernel.dylib
     0x7fff8c5c2000 -     0x7fff8c610fff  libauto.dylib (??? - 
???)<D8AC8458-DDD0-3939-8B96-B6CED81613EF>  /usr/lib/libauto.dylib
     0x7fff8c611000 -     0x7fff8c612ff7  libsystem_blocks.dylib (53.0.0 - 
compatibility 1.0.0)<8BCA214A-8992-34B2-A8B9-B74DEACA1869>  
/usr/lib/system/libsystem_blocks.dylib
     0x7fff8c613000 -     0x7fff8c61eff7  libc++abi.dylib (14.0.0 - compatibility 
1.0.0)<8FF3D766-D678-36F6-84AC-423C878E6D14>  /usr/lib/libc++abi.dylib
     0x7fff8c642000 -     0x7fff8c684ff7  libcommonCrypto.dylib (55010.0.0 - 
compatibility 1.0.0)<A5B9778E-11C3-3F61-B740-1F2114E967FB>  
/usr/lib/system/libcommonCrypto.dylib
     0x7fff8cc57000 -     0x7fff8cc92fff  libsystem_info.dylib (??? - 
???)<35F90252-2AE1-32C5-8D34-782C614D9639>  /usr/lib/system/libsystem_info.dylib
     0x7fff8daf3000 -     0x7fff8daf4ff7  libremovefile.dylib (21.1.0 - compatibility 
1.0.0)<739E6C83-AA52-3C6C-A680-B37FE2888A04>  
/usr/lib/system/libremovefile.dylib
     0x7fff8e5e5000 -     0x7fff8e5e6fff  libunc.dylib (24.0.0 - compatibility 
1.0.0)<C67B3B14-866C-314F-87FF-8025BEC2CAAC>  /usr/lib/system/libunc.dylib
     0x7fff8ed40000 -     0x7fff8ed41ff7  libsystem_sandbox.dylib (??? - 
???)<5087ADAD-D34D-3844-9D04-AFF93CED3D92>  
/usr/lib/system/libsystem_sandbox.dylib
     0x7fff8f068000 -     0x7fff8f071ff7  libsystem_notify.dylib (80.1.0 - 
compatibility 1.0.0)<A4D651E3-D1C6-3934-AD49-7A104FD14596>  
/usr/lib/system/libsystem_notify.dylib

Any help appreciated, thanks :)

--
Daniel O'Connor software and network engineer
for Genesis Software - http://www.gsoft.com.au
"The nice thing about standards is that there
are so many of them to choose from."
   -- Andrew Tanenbaum
GPG Fingerprint - 5596 B766 97C0 0E94 4347 295E E593 DC20 7B3F CE8C







_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio

_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio

Reply via email to