Boost logo

Boost-Build :

From: David Abrahams (dave_at_[hidden])
Date: 2007-05-26 10:41:24


on Sat May 26 2007, Vladimir Prus <ghost-AT-cs.msu.su> wrote:

> Please add
>
> using python ;
>
> to tools/build/v2/user-config.jam, as otherwise the 'quickstart' project
> won't get any python support whatsoever. Dave, do you think some doc change,
> or code change is required to solve this issue?

I'm very surprised to see this, as I implemented and tested python
auto-configuration myself. The very top of
libs/python/build/Jamfile.v2 contains:

  import python ;

  if ! [ python.configured ] && ! ( --without-python in [ modules.peek : ARGV ] )
  {
      # Attempt default configuration of python
      import toolset : using ;
      using python ;

      if ! [ python.configured ]
      {
          ECHO "WARNING: No python installation configured and autoconfiguration" ;
          ECHO " failed. See http://www.boost.org/libs/python/doc/building.html" ;
          ECHO " for configuration instructions or pass --without-python to" ;
          ECHO " suppress this message and silently skip all Boost.Python targets" ;
      }
  }

...oh, maybe the order of targets in the quickstart example got
changed at the last minute.

  # Set up the project-wide requirements that everything uses the
  # boost_python library defined in the project whose global ID is
  # /boost/python.
  project
    : requirements <library>/boost/python//boost_python ;

  # Declare a Python extension called hello.
  python-extension extending : extending.cpp ;

  # Declare an executable called embedding that embeds Python
  exe embedding : embedding.cpp /python//python ;

If it was the other way around, presumably the dependency on the
boost_python target would have caused libs/python/build/Jamfile.v2 to
be read.

-- 
Dave Abrahams
Boost Consulting
http://www.boost-consulting.com

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