ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> cpp-sig
cpp-sig
Re: [C++-sig] Boost V1 build on Solaris
by David Abrahams other posts by this author
Oct 24 2002 10:00PM messages near this date
Re: [C++-sig] Boost V1 build on Solaris | Re: [C++-sig] Boost V1 build on Solaris
Leonardo Rochael Almeida <leo@[...].br>  writes:

>  On Wed, 2002-10-23 at 22:36, Paul F. Kunz wrote:
>  >    One final question, which is not specific to boost::python but
>  > general question on building Python modules.   What my Solaris
>  > administrators have done is to configure Python with 
>  > 
>  > >  ./configure
>  >  --prefix=/afs/.slac.stanford.edu/package/python/common/2.0
>  >  --exec-prefix=/afs/.slac.stanford.edu/package/python/sun4x_55/2.0
>  > 
>  > They also did a build fron Linux with the appropriate `exec-prefix'.
>  > What apparently this has done is to put all but one of the Python
>  > include files in the directory `common/2.0/include'.  But Python.h
>  > includes `config.h' or `pyconfig.h' (depending on the version) which
>  > gets installed in `sun4x_55/2.0/include'.  This is appropriate since
>  > this file is machine/OS dependent.
>  > 
>  >    Now the problem is that boost::python, and other packages, gives you
>  > one variable, like PYTHON_INCLUDES,  for its build.   When it is set to find
>  > `Python.h' it will not find `pyconfig.h'.   
>  > 
>  >    What is the best way to handle this situation?   Is it a bug in
>  > Python's configure script?   Bug in boost::python and others?   Or am
>  > I missing something obvious?
>  
>  Your setup requires that sun4x_55/2.0/include is in the include path
>  somehow (i.e. it should be in the -I parameter of all compiler
>  invocations). Reading <boost>tools/build/gcc-tools.jam makes me believe
>  that you can make your setup work by adding the following line to your
>  <boost>/Jamrules file:
>  
>  STDHDRS += /afs/.slac.stanford.edu/package/python/sun4x_55/2.0

That's generally /not/ the way you're intended to use the build
system. You can do this, but it's not going to work in future versions
of the build system and it could do unexpected things when you build
targets other than Boost.Python and Boost.Python extensions.  The
right thing to do is to add something like:

  PYTHON_PROPERTIES += <sysinclude> $(PYTHON:D)/include ;

to the end of tools/build/python.jam, but I don't want to make that
change until I hear from python-dev about what's going on here. In the
meantime, you can do it in the Jamfiles after python.jam is included.

-- 
                    David Abrahams
dave@[...].com * http://www.boost-consulting.com

Building C/C++ Extensions for Python: Dec 9-11, Austin, TX
http://www.enthought.com/training/building_extensions.html


_______________________________________________
C++-sig mailing list
C++-sig@[...].org
http://mail.python.org/mailman/listinfo/c++-sig
Thread:
Paul F. Kunz
Paul F. Kunz
David Abrahams
Leonardo Rochael Almeida
David Abrahams
David Abrahams
David Abrahams
David Abrahams
Leonardo Rochael Almeida
David Abrahams
Paul F. Kunz
David Abrahams
Paul F. Kunz
Paul F. Kunz

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved