2
0
mirror of https://github.com/boostorg/build.git synced 2026-02-16 01:12:13 +00:00

Merge from trunk.

[SVN r33579]
This commit is contained in:
Vladimir Prus
2006-04-07 07:38:58 +00:00
parent 0b0d55bb05
commit 1d45ae211b
4 changed files with 30 additions and 11 deletions

View File

@@ -471,14 +471,6 @@ rule add-prefix-and-suffix ( specified-name : type ? : property-set )
local prefix = [ type.generated-target-prefix $(type) : $(property-set) ] ;
# if ! $(prefix)
# && [ type.is-derived $(type) LIB ] && [ os.on-unix ]
# # This becomes hacky! Need to introduce more general mechanism.
# # Invoke type.set-target-prefix in unix toolkit?
# && ! [ type.is-derived $(type) PYTHON_EXTENSION ]
# {
# prefix = lib ;
# }
if [ MATCH ^($(prefix)) : $(specified-name) ]
{
prefix = ;

View File

@@ -317,6 +317,8 @@ rule init-link-flags ( toolset linker condition )
: unchecked ;
flags $(toolset).link RPATH $(condition) : <dll-path> : unchecked ;
flags $(toolset).link RPATH_LINK $(condition) : <xdll-path> : unchecked ;
flags $(toolset).link START-GROUP $(condition) : -Wl,--start-group : unchecked ;
flags $(toolset).link END-GROUP $(condition) : -Wl,--end-group : unchecked ;
}
case darwin :
{
@@ -383,7 +385,7 @@ rule link ( targets * : sources * : properties * )
actions link bind LIBRARIES
{
"$(CONFIG_COMMAND)" -L"$(LINKPATH)" -Wl,$(RPATH_OPTION:E=-R)$(SPACE)-Wl,"$(RPATH)" -Wl,-rpath-link$(SPACE)-Wl,"$(RPATH_LINK)" -o "$(<)" "$(>)" "$(LIBRARIES)" -l$(FINDLIBS-ST) -l$(FINDLIBS-SA) $(OPTIONS) $(USER_OPTIONS)
"$(CONFIG_COMMAND)" -L"$(LINKPATH)" -Wl,$(RPATH_OPTION:E=-R)$(SPACE)-Wl,"$(RPATH)" -Wl,-rpath-link$(SPACE)-Wl,"$(RPATH_LINK)" -o "$(<)" $(START-GROUP) "$(>)" "$(LIBRARIES)" -l$(FINDLIBS-ST) -l$(FINDLIBS-SA) $(END-GROUP) $(OPTIONS) $(USER_OPTIONS)
}
@@ -441,7 +443,7 @@ rule link.dll ( targets * : sources * : properties * )
# Differ from 'link' above only by -shared.
actions link.dll bind LIBRARIES
{
"$(CONFIG_COMMAND)" -L"$(LINKPATH)" -Wl,$(RPATH_OPTION:E=-R)$(SPACE)-Wl,"$(RPATH)" -o "$(<)" $(HAVE_SONAME)-Wl,$(SONAME_OPTION)$(SPACE)-Wl,$(<[1]:D=) -shared "$(>)" "$(LIBRARIES)" -l$(FINDLIBS-ST) -l$(FINDLIBS-SA) $(OPTIONS) $(USER_OPTIONS)
"$(CONFIG_COMMAND)" -L"$(LINKPATH)" -Wl,$(RPATH_OPTION:E=-R)$(SPACE)-Wl,"$(RPATH)" -o "$(<)" $(HAVE_SONAME)-Wl,$(SONAME_OPTION)$(SPACE)-Wl,$(<[1]:D=) -shared $(START-GROUP) "$(>)" "$(LIBRARIES)" -l$(FINDLIBS-ST) -l$(FINDLIBS-SA) $(END-GROUP) $(OPTIONS) $(USER_OPTIONS)
}
# Set up threading support. It's somewhat contrived, so perform it at the end,

View File

@@ -128,6 +128,22 @@ rule init-unix ( version ? : root ? : includes ? : libraries ? : condition * )
{
flags python.capture-output PYTHON $(condition:J=/) : $(interpreter) ;
}
local extra-libs ;
if [ os.name ] = SOLARIS
{
extra-libs = dl ;
}
else if [ os.name ] = OSF || [ os.name ] = QNXTO
{
# Nothing.
}
else
{
extra-libs = dl util ;
}
# On Linux, we don't want to link either Boost.Python or
# Python extensions to libpython, so that when extensions
@@ -143,7 +159,7 @@ rule init-unix ( version ? : root ? : includes ? : libraries ? : condition * )
;
alias python
: dl util
: $(extra-libs)
: $(condition)
:
: <include>$(includes)
@@ -373,6 +389,9 @@ type.set-generated-target-suffix PYTHON_EXTENSION : : so ;
type.set-generated-target-suffix PYTHON_EXTENSION : <os>NT : dll ;
type.set-generated-target-suffix PYTHON_EXTENSION : <os>CYGWIN : so ;
# Unset 'lib' prefix for PYTHON_EXTENSION
type.set-generated-target-prefix PYTHON_EXTENSION : : "" ;
rule python-extension ( name : sources * : requirements * : default-build * :
usage-requirements * )
{

View File

@@ -3,9 +3,15 @@
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
import type ; # for set-generated-target-suffix
import os ;
type.register LIB ;
if [ os.on-unix ]
{
type.set-generated-target-prefix LIB : : "lib" ;
}
type STATIC_LIB : lib a : LIB : NT CYGWIN ;
type STATIC_LIB : a : LIB : MACOSX ;
type STATIC_LIB : a : LIB ;