added -fPIC and -fvisibility=hidden as features for cleaner Jamfile (and to make the propagation work for boost_system)
This commit is contained in:
parent
16bfde875d
commit
24668058fc
27
Jamfile
27
Jamfile
|
@ -110,21 +110,10 @@ rule linking ( properties * )
|
|||
{
|
||||
if <boost-link>static in $(properties)
|
||||
{
|
||||
if <toolset>darwin in $(properties) || <toolset>gcc in $(properties)
|
||||
{
|
||||
result += <library>/boost/thread//boost_thread/<link>static/<cflags>-fvisibility=hidden
|
||||
<library>/boost/filesystem//boost_filesystem/<link>static/<cflags>-fvisibility=hidden
|
||||
<library>/boost/system//boost_system/<link>static
|
||||
#/<cflags>-fvisibility=hidden
|
||||
;
|
||||
}
|
||||
else
|
||||
{
|
||||
result += <library>/boost/thread//boost_thread/<link>static
|
||||
<library>/boost/filesystem//boost_filesystem/<link>static
|
||||
<library>/boost/system//boost_system/<link>static
|
||||
;
|
||||
}
|
||||
result += <library>/boost/thread//boost_thread/<link>static
|
||||
<library>/boost/filesystem//boost_filesystem/<link>static
|
||||
<library>/boost/system//boost_system/<link>static
|
||||
;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -155,7 +144,7 @@ rule building ( properties * )
|
|||
|
||||
if <toolset>gcc in $(properties) || <toolset>darwin in $(properties)
|
||||
{
|
||||
result += <cflags>-fvisibility=hidden ;
|
||||
result += <visibility>hidden ;
|
||||
}
|
||||
|
||||
if ( <target-os>linux in $(properties)
|
||||
|
@ -260,6 +249,12 @@ feature.compose <debug-iterators>on : <define>_SCL_SECURE=1 <define>_GLIBCXX_DEB
|
|||
|
||||
feature test-coverage : off on : composite propagated ;
|
||||
|
||||
feature fpic : off on : composite propagated link-incompatible ;
|
||||
feature.compose <fpic>on : <cflags>-fPIC ;
|
||||
|
||||
feature visibility : defeault hidden : composite propagated link-incompatible ;
|
||||
feature.compose <visibility>hidden : <cflags>-fvisibility=hidden ;
|
||||
|
||||
# required for openssl on windows
|
||||
lib ssleay32 : : <name>ssleay32 ;
|
||||
lib libeay32 : : <name>libeay32 ;
|
||||
|
|
|
@ -10,26 +10,12 @@ rule libtorrent_linking ( properties * )
|
|||
|
||||
if <toolset>gcc in $(properties)
|
||||
{
|
||||
result += <library>/torrent//torrent/<link>static/<cflags>-fPIC
|
||||
<cflags>-fPIC ;
|
||||
}
|
||||
else
|
||||
{
|
||||
result += <library>/torrent//torrent/<link>static ;
|
||||
result += <fpic>on ;
|
||||
}
|
||||
|
||||
if <toolset>gcc in $(properties) || <toolset>darwin in $(properties)
|
||||
{
|
||||
result += <cflags>-fvisibility=hidden ;
|
||||
|
||||
if <boost>source in $(properties) && <boost-link>static in $(properties)
|
||||
{
|
||||
result += <library>/boost/python//boost_python/<link>static/<cflags>-fvisibility=hidden ;
|
||||
}
|
||||
}
|
||||
else if <boost>source in $(properties) && <boost-link>static in $(properties)
|
||||
{
|
||||
result += <library>/boost/python//boost_python/<link>static ;
|
||||
result += <visibility>hidden ;
|
||||
}
|
||||
|
||||
# when building peer_plugin.cpp on msvc-7.1 it fails
|
||||
|
@ -68,7 +54,9 @@ python-extension libtorrent
|
|||
src/ip_filter.cpp
|
||||
src/magnet_uri.cpp
|
||||
: <include>src
|
||||
<library>/torrent//torrent/<link>static
|
||||
<boost>system:<library>boost_python
|
||||
<boost>source,<boost-link>static:<library>/boost/python//boost_python/<link>static
|
||||
<boost>source,<boost-link>shared:<library>/boost/python//boost_python/<link>shared
|
||||
<conditional>@libtorrent_linking
|
||||
;
|
||||
|
|
Loading…
Reference in New Issue