Files
regex/build/Jamfile.v2
John Maddock 71a0e020e2 merged changes in regex5 branch
[SVN r26692]
2005-01-13 17:06:21 +00:00

127 lines
3.1 KiB
Plaintext

project boost/regex
: source-location ../src
;
#
# ICU configuration:
#
local ICU_PATH = [ modules.peek : ICU_PATH ] ;
rule check-icu-config ( )
{
local ICU_PATH = [ modules.peek : ICU_PATH ] ;
if ! $(gICU_CONFIG_CHECKED)
{
if $(ICU_PATH)
{
dir = $(ICU_PATH) ;
}
if [ GLOB $(dir)/include/unicode : utypes.h ]
{
ECHO Building Boost.Regex with Unicode/ICU support enabled ;
ECHO Using ICU in $(ICU_PATH:J=" ")/include ;
gHAS_ICU = true ;
# try and find ICU libraries, look for NT versions first:
if [ GLOB $(dir)/lib : icuuc.* ]
{
gICU_CORE_LIB = icuuc ;
}
else if [ GLOB $(dir)/lib : libicuuc.* ]
{
gICU_CORE_LIB = icuuc ;
}
else if [ GLOB $(ICU_PATH)/lib : cygicuuc.dll ]
{
gICU_CORE_LIB = cygicuuc.dll ;
}
else
{
ECHO ICU shared common library not found. ;
}
if [ GLOB $(dir)/lib : icuin.* ]
{
gICU_IN_LIB = icuin ;
}
else if [ GLOB $(dir)/lib : libicui18n.* ]
{
gICU_IN_LIB = icuin ;
}
else if [ GLOB $(ICU_PATH)/lib : cygicuin.dll ]
{
gICU_IN_LIB = cygicuin.dll ;
}
else
{
ECHO ICU shared i18n library not found. ;
}
}
else
{
ECHO ****************************************************** ;
ECHO ;
ECHO Building Boost.Regex with Unicode/ICU support disabled. ;
ECHO HINT: define the environment variable ICU_PATH to point to the ;
ECHO root directy of your ICU installation if you have one. ;
ECHO Couldn't find utypes.h in \"$(ICU_PATH:J=" ")/include/unicode\" ;
ECHO ;
ECHO ****************************************************** ;
}
gICU_CONFIG_CHECKED = true ;
}
if $(gHAS_ICU)
{
return true ;
}
}
if [ check-icu-config ]
{
BOOST_REGEX_ICU_OPTS = "<define>BOOST_HAS_ICU=1" ;
if $(gICU_CORE_LIB)
{
lib icucore : : <name>$(gICU_CORE_LIB) <search>/$(ICU_PATH)/lib ;
ICU_EXTRA_SOURCE = icucore ;
}
if $(gICU_IN_LIB)
{
lib icuin : : <name>$(gICU_IN_LIB) <search>/$(ICU_PATH)/lib ;
ICU_EXTRA_SOURCE += icuin ;
}
if $(ICU_PATH)
{
BOOST_REGEX_ICU_OPTS += "<include>$(ICU_PATH)/include" ;
#BOOST_REGEX_ICU_OPTS += "<library-path>$(ICU_PATH)/lib" ;
}
}
SOURCES =
c_regex_traits.cpp
cpp_regex_traits.cpp
cregex.cpp
fileiter.cpp
icu.cpp
instances.cpp
posix_api.cpp
regex.cpp
regex_debug.cpp
regex_raw_buffer.cpp
regex_traits_defaults.cpp
static_mutex.cpp
w32_regex_traits.cpp
wc_regex_traits.cpp
wide_posix_api.cpp
winstances.cpp
usinstances.cpp ;
lib boost_regex : ../src/$(SOURCES) $(ICU_EXTRA_SOURCE)
:
#<link>static:<define>BOOST_REGEX_NO_LIB=1
#<link>static:<define>BOOST_REGEX_STATIC_LINK=1
<link>shared:<define>BOOST_REGEX_DYN_LINK=1
$(BOOST_REGEX_ICU_OPTS)
;