Update of /cvsroot/boost/boost/tools/build/v2/tools
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv7462
Modified Files:
Tag: RC_1_34_0
python.jam
Log Message:
Some simplifications. Building on Cygwin from an NT bjam is broken again :(
Index: python.jam
===================================================================
RCS file: /cvsroot/boost/boost/tools/build/v2/tools/python.jam,v
retrieving revision 1.12.2.41
retrieving revision 1.12.2.42
diff -u -d -r1.12.2.41 -r1.12.2.42
--- python.jam 21 Mar 2007 05:42:31 -0000 1.12.2.41
+++ python.jam 21 Mar 2007 08:02:27 -0000 1.12.2.42
@@ -468,7 +468,6 @@
target-os : version ? : prefix ? : exec-prefix ? )
{
exec-prefix ?= $(prefix) ;
- executable ?= $(:E=python:R=$(exec-prefix)) ;
if $(target-os) = windows
{
@@ -616,9 +615,8 @@
}
}
-# Declare a target to represent Python's library, returning the target
-# name.
-local rule declare-libpython-target ( version ? : sys.platform ? :
requirements * )
+# Declare a target to represent Python's library.
+local rule declare-libpython-target ( version ? : requirements * )
{
# Compute the representation of Python version in the name of
# Python's library file.
@@ -629,13 +627,16 @@
lib-version = $(major-minor:J="") ;
}
- # Compute the name of the target to declare
- local libpython-target-name = python $(version) $(sys.platform) ;
- libpython-target-name = $(libpython-target-name:J=-).lib ;
+ if ! $(lib-version)
+ {
+ ECHO *** warning: could not determine Python version, which will ;
+ ECHO *** warning: probably prevent us from linking with the python ;
+ ECHO *** warning: library. Consider explicitly passing the version ;
+ ECHO *** warning: to 'using python'. ;
+ }
- # Declare and return it
- searched-lib $(libpython-target-name) : : <name>python$(lib-version)
$(requirements) ;
- return $(libpython-target-name) ;
+ # Declare it
+ lib python.lib : : <name>python$(lib-version) $(requirements) ;
}
# implementation of init
@@ -727,8 +728,6 @@
{
debug-message ...requested configuration matched! ;
- executable ?= $(sys.executable) ;
-
compute-default-paths
$(target-os) : $(sys.version)
: $(sys.prefix)
@@ -746,7 +745,7 @@
}
# Anything left to compute?
- if ! ( $(includes) && $(libraries) && $(executable) )
+ if ! ( $(includes) && $(libraries) && $(interpreter-cmd) )
{
version ?= $(fallback-version) ;
version ?= 2.5 ;
@@ -761,15 +760,13 @@
ECHO warning: falling back to \"$(interpreter-cmd)\" ;
}
}
- compute-default-paths $(target-os) : $(version) : $(prefix) ;
+ compute-default-paths $(target-os) : $(version) : $(sys.prefix:E=)
;
}
}
- local executable-dir = $(executable:D) ;
debug-message "Python interpreter command is"
\"$(interpreter-cmd:E=<empty>)\" ;
debug-message "Python include path is" \"$(includes:E=<empty>)\" ;
debug-message "Python library path is" \"$(libraries:E=<empty>)\" ;
- debug-message "Python executable directory is"
\"$(executable-dir:E=<empty>)\" ;
#
# End autoconfiguration sequence
@@ -828,9 +825,9 @@
# Make sure that we can find the Python DLL on windows
local dll-path ;
- if $(target-os) = windows
+ if $(target-os) = windows && $(sys.exec_prefix)
{
- dll-path += $(executable-dir) ;
+ dll-path += $(sys.exec_prefix) ;
}
#
@@ -849,14 +846,16 @@
}
else
{
- local libpython-target-name
- = [ declare-libpython-target $(version) : $(sys.platform) :
$(target-requirements) ] ;
-
+ declare-libpython-target $(version) : $(target-requirements) ;
alias python
- : $(system-libs)
- : $(target-requirements)
+ : $(system-libs)
+ : $(target-requirements)
:
- : <include>$(includes) <library-path>$(libraries)
<library>$(libpython-target-name) <dll-path>$(dll-path)
+ # why python.lib must be listed here instead of along with
+ # the system libs is a mystery, but if we don't do it, on
+ # cygwin -lpythonX.Y never appears in the command line
+ # (although it does on linux).
+ : <include>$(includes) <library-path>$(libraries)
<dll-path>$(dll-path) <library>python.lib
;
}
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Boost-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/boost-cvs