471,354 Members | 1,629 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,354 software developers and data experts.

Problems with Boost.Python

I'm trying to get Boost.Python to working using the instructions here: http://www.boost.org/libs/python/doc/building.html. I am on step 3.1.4 and am getting a linking error that I can't figure out. This is the error:

Expand|Select|Wrap|Line Numbers
  1. ~/Desktop/boost_1_34_1/libs/python/example/quickstart$ bjam toolset=gcc --verbose-test test
  2. Building Boost.Regex with the optional Unicode/ICU support disabled.
  3. Please refer to the Boost.Regex documentation for more information
  4. (don't panic: this is a strictly optional feature).
  5. ...patience...
  6. ...found 1085 targets...
  7. ...using 1 temp target...
  8. ...updating 5 targets...
  9. ...using <pbin/gcc-4.1.2/debug>extending.so...
  10. capture-output bin/test_ext.test/gcc-4.1.2/debug/test_ext
  11. ====== BEGIN OUTPUT ======
  12. Trying:
  13.     from extending import *
  14. Expecting nothing
  15. ok
  16. Trying:
  17.     hi = hello('California')
  18. Expecting nothing
  19. ok
  20. Trying:
  21.     hi.greet()
  22. Expecting:
  23.     'Hello from California'
  24. ok
  25. Trying:
  26.     invite(hi)
  27. Expecting:
  28.     'Hello from California! Please come soon!'
  29. ok
  30. Trying:
  31.     hi.invite()
  32. Expecting:
  33.     'Hello from California! Please come soon!'
  34. ok
  35. Trying:
  36.     class wordy(hello):
  37.         def greet(self):
  38.             return hello.greet(self) + ', where the weather is fine'
  39. Expecting nothing
  40. ok
  41. Trying:
  42.     hi2 = wordy('Florida')
  43. Expecting nothing
  44. ok
  45. Trying:
  46.     hi2.greet()
  47. Expecting:
  48.     'Hello from Florida, where the weather is fine'
  49. ok
  50. Trying:
  51.     invite(hi2)
  52. Expecting:
  53.     'Hello from Florida! Please come soon!'
  54. ok
  55. 1 items had no tests:
  56.     test_extending.run
  57. 1 items passed all tests:
  58.    9 tests in test_extending
  59. 9 tests in 2 items.
  60. 9 passed and 0 failed.
  61. Test passed.
  62.  
  63. EXIT STATUS: 0
  64. ====== END OUTPUT ======
  65. **passed** bin/test_ext.test/gcc-4.1.2/debug/test_ext.test
  66. gcc.link bin/gcc-4.1.2/debug/embedding
  67. /usr/bin/ld: cannot find -lpython2.5
  68. collect2: ld returned 1 exit status
  69.  
  70.     "g++" -L"/usr/lib" -L"/usr/lib/python2.5/config" -Wl,-R -Wl,"/home/lolomg/Desktop/boost_1_34_1/bin.v2/libs/python/build/gcc-4.1.2/debug" -Wl,-R -Wl,"/usr/lib" -Wl,-R -Wl,"/usr/lib/python2.5/config" -Wl,-rpath-link -Wl,"/home/lolomg/Desktop/boost_1_34_1/bin.v2/libs/python/build/gcc-4.1.2/debug" -o "bin/gcc-4.1.2/debug/embedding" -Wl,--start-group "bin/gcc-4.1.2/debug/embedding.o" "../../../../bin.v2/libs/python/build/gcc-4.1.2/debug/libboost_python-gcc41-d-1_34_1.so.1.34.1"   -lpython2.5 -lutil -lpthread -ldl -Wl,--end-group -g 
  71.  
  72. ...failed gcc.link bin/gcc-4.1.2/debug/embedding...
  73. ...skipped <pbin/test_embed.test/gcc-4.1.2/debug>test_embed.run for lack of <pbin/gcc-4.1.2/debug>embedding...
  74. ...failed updating 1 target...
  75. ...skipped 2 targets...
  76. ...updated 2 targets...
  77.  
I using Ubuntu 7.04 and Python 2.5. I've tried configuring the .jam file, but it didn't seem to help. Any help would be appreciated--I'm stuck here, and I'm a bit hazy on compilers/linkers to begin with (I haven't taken the compiler class in school yet). Thanks.
Sep 11 '07 #1
0 1982

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

reply views Thread by Gouda Man | last post: by
reply views Thread by Li Daobing | last post: by
reply views Thread by Andrew Ayre | last post: by
1 post views Thread by Max Wilson | last post: by
4 posts views Thread by Shawn McGrath | last post: by
2 posts views Thread by mr_gees100_peas | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.