change ICU_LINK configuration

This commit is contained in:
John Maddock
2019-10-25 19:05:52 +01:00
parent 8a8ceab94a
commit fc4dc17dc7

View File

@ -5,6 +5,7 @@
import modules ; import modules ;
import testing ; import testing ;
import errors ;
project : requirements project : requirements
# default to all warnings on: # default to all warnings on:
@ -32,19 +33,31 @@ rule path_options ( properties * )
# #
if ! $(disable-icu) if ! $(disable-icu)
{ {
if [ modules.peek : ICU_LINK ]
{
errors.user-error : "The ICU_LINK option is no longer supported by the Boost.Regex build - please refer to the documentation for equivalent options" ;
}
if [ modules.peek : ICU_PATH ] if [ modules.peek : ICU_PATH ]
{ {
ICU_PATH = [ modules.peek : ICU_PATH ] ; ICU_PATH = [ modules.peek : ICU_PATH ] ;
} }
if [ modules.peek : ICU_LINK ] if [ modules.peek : ICU_ICUUC_NAME ]
{ {
ICU_LINK = [ modules.peek : ICU_LINK ] ; ICU_ICUUC_NAME = [ modules.peek : ICU_ICUUC_NAME ] ;
}
if [ modules.peek : ICU_ICUDT_NAME ]
{
ICU_ICUDT_NAME = [ modules.peek : ICU_ICUDT_NAME ] ;
}
if [ modules.peek : ICU_ICUIN_NAME ]
{
ICU_ICUIN_NAME = [ modules.peek : ICU_ICUIN_NAME ] ;
} }
if $(ICU_LINK) if $(ICU_ICUUC_NAME)
{ {
ICU_OPTS = <include>$(ICU_PATH)/include <linkflags>$(ICU_LINK) <dll-path>$(ICU_PATH)/bin <define>BOOST_HAS_ICU=1 <runtime-link>shared ; lib icuuc : : <name>$(ICU_ICUUC_NAME) ;
} }
else else
{ {
@ -55,7 +68,13 @@ if ! $(disable-icu)
lib icuuc : : <toolset>msvc <variant>debug <name>sicuucd <runtime-link>static <conditional>@path_options ; lib icuuc : : <toolset>msvc <variant>debug <name>sicuucd <runtime-link>static <conditional>@path_options ;
lib icuuc : : <toolset>intel <target-os>windows <variant>debug <name>sicuucd <runtime-link>static <conditional>@path_options ; lib icuuc : : <toolset>intel <target-os>windows <variant>debug <name>sicuucd <runtime-link>static <conditional>@path_options ;
lib icuuc : : <name>this_is_an_invalid_library_name ; lib icuuc : : <name>this_is_an_invalid_library_name ;
}
if $(ICU_ICUDT_NAME)
{
lib icudt : : <name>$(ICU_ICUDT_NAME) ;
}
else
{
lib icudt : : <name>icudata <runtime-link>shared <conditional>@path_options ; lib icudt : : <name>icudata <runtime-link>shared <conditional>@path_options ;
lib icudt : : <name>icudt <toolset>msvc <runtime-link>shared <conditional>@path_options ; lib icudt : : <name>icudt <toolset>msvc <runtime-link>shared <conditional>@path_options ;
lib icudt : : <name>icudt <toolset>intel <target-os>windows <runtime-link>shared <conditional>@path_options ; lib icudt : : <name>icudt <toolset>intel <target-os>windows <runtime-link>shared <conditional>@path_options ;
@ -63,7 +82,13 @@ if ! $(disable-icu)
lib icudt : : <name>sicudt <toolset>msvc <runtime-link>static <conditional>@path_options ; lib icudt : : <name>sicudt <toolset>msvc <runtime-link>static <conditional>@path_options ;
lib icudt : : <name>sicudt <toolset>intel <target-os>windows <runtime-link>static <conditional>@path_options ; lib icudt : : <name>sicudt <toolset>intel <target-os>windows <runtime-link>static <conditional>@path_options ;
lib icudt : : <name>this_is_an_invalid_library_name ; lib icudt : : <name>this_is_an_invalid_library_name ;
}
if $(ICU_ICUIN_NAME)
{
lib icuin : : <name>$(ICU_ICUIN_NAME) ;
}
else
{
lib icuin : : <name>icui18n <runtime-link>shared <conditional>@path_options ; lib icuin : : <name>icui18n <runtime-link>shared <conditional>@path_options ;
lib icuin : : <toolset>msvc <variant>debug <name>icuind <runtime-link>shared <conditional>@path_options ; lib icuin : : <toolset>msvc <variant>debug <name>icuind <runtime-link>shared <conditional>@path_options ;
lib icuin : : <toolset>msvc <name>icuin <runtime-link>shared <conditional>@path_options ; lib icuin : : <toolset>msvc <name>icuin <runtime-link>shared <conditional>@path_options ;
@ -75,20 +100,20 @@ if ! $(disable-icu)
lib icuin : : <toolset>intel <target-os>windows <variant>debug <name>sicuind <runtime-link>static <conditional>@path_options ; lib icuin : : <toolset>intel <target-os>windows <variant>debug <name>sicuind <runtime-link>static <conditional>@path_options ;
lib icuin : : <toolset>intel <target-os>windows <name>sicuin <runtime-link>static <conditional>@path_options ; lib icuin : : <toolset>intel <target-os>windows <name>sicuin <runtime-link>static <conditional>@path_options ;
lib icuin : : <name>this_is_an_invalid_library_name ; lib icuin : : <name>this_is_an_invalid_library_name ;
ICU_OPTS =
<include>$(ICU_PATH)/include
<runtime-link>shared:<library>icuuc/<link>shared
<runtime-link>shared:<library>icudt/<link>shared
<runtime-link>shared:<library>icuin/<link>shared
<runtime-link>static:<library>icuuc
<runtime-link>static:<library>icudt
<runtime-link>static:<library>icuin
<define>BOOST_HAS_ICU=1
<runtime-link>static:<define>U_STATIC_IMPLEMENTATION=1
;
} }
ICU_OPTS =
<include>$(ICU_PATH)/include
<runtime-link>shared:<library>icuuc/<link>shared
<runtime-link>shared:<library>icudt/<link>shared
<runtime-link>shared:<library>icuin/<link>shared
<runtime-link>static:<library>icuuc
<runtime-link>static:<library>icudt
<runtime-link>static:<library>icuin
<define>BOOST_HAS_ICU=1
<runtime-link>static:<define>U_STATIC_IMPLEMENTATION=1
;
} }
unit-test has_icu : has_icu_test.cpp : $(ICU_OPTS) ; unit-test has_icu : has_icu_test.cpp : $(ICU_OPTS) ;