Boost logo

Boost-Build :

Subject: Re: [Boost-build] Using bjam on OS X for Python extensions
From: Vladimir Prus (ghost_at_[hidden])
Date: 2010-03-29 05:40:57


aditya bhargava wrote:
> I'm trying learn how to create a Python extension using bjam, and I'm
> walking through the basic "Hello World" tutorial on boost.org
> <http://boost.org>. Running bjam compiles my code into an object file,
> but for some reason it is not able to create a shared library. Here's
> what I see:
>
> ...patience...
> ...patience...
> ...found 1573 targets...
> ...updating 11 targets...
> common.mkdir bin
> common.mkdir bin/gcc-4.0.1
> common.mkdir bin/gcc-4.0.1/debug
> gcc.compile.c++ bin/gcc-4.0.1/debug/hello.o
> gcc.link.dll
> /usr/local/boost/bin.v2/libs/python/build/gcc-4.0.1/debug/libboost_python.dylib
> *i686-apple-darwin8-g++-4.0.1: unrecognized option '-shared'*
> /usr/libexec/gcc/i686-apple-darwin8/4.0.1/ld: unknown flag: -R
> collect2: ld returned 1 exit status

Please use "toolset=darwin" on the command line. This inconvenience is fixed in SVN --
the 'darwin' toolset is not the default on OSX.

- Volodya


Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk