Compare commits

...

6 Commits

Author SHA1 Message Date
ad7046fa0b creating branch to fix intrusive for Sun CC (#3339)
[SVN r55764]
2009-08-24 17:08:35 +00:00
9f9ce59d57 Treat ICU_PATH relatively to current dir.
Also, fix another leading "/" bug.


[SVN r55756]
2009-08-24 09:34:08 +00:00
2686ab22a2 Don't add leading slash to every path.
[SVN r55731]
2009-08-23 15:50:50 +00:00
75b99d3a37 Suppress GCC warnings.
[SVN r55688]
2009-08-20 17:27:24 +00:00
bae1c80992 Force shared runtime if using ICU.
[SVN r55685]
2009-08-20 12:05:55 +00:00
e3ca2987e4 Apply patch from issue #3354.
Fixes #3354.

[SVN r55683]
2009-08-20 10:43:44 +00:00
3 changed files with 41 additions and 4 deletions

View File

@ -192,15 +192,22 @@ if [ check-icu-config ]
if $(gHAS_ICU)
{
BOOST_REGEX_ICU_OPTS = "<target-os>freebsd:<include>/usr/local/include" ;
ICU_SEARCH_OPTS = "<target-os>freebsd:<search>/$(ICU_PATH)/lib" ;
ICU_SEARCH_OPTS = "<target-os>freebsd:<search>$(ICU_PATH)/lib" ;
BOOST_REGEX_ICU_OPTS += "<define>BOOST_HAS_ICU=1" ;
if $(ICU_PATH)
{
# If ICU_PATH is specified on the command line, then it's
# relative to the current directory, while paths specified
# in a Jamfile are relative to that Jamfile. So, to
# avoid confusing the user if he's not running from
# libs/regex/build, explicitly root this.
ICU_PATH = [ path.native
[ path.root [ path.make $(ICU_PATH) ] [ path.pwd ] ] ] ;
if $(ICU_PATH) != "/usr" && $(ICU_PATH) != "/usr/local"
{
BOOST_REGEX_ICU_OPTS += "<include>$(ICU_PATH)/include" ;
ICU_SEARCH_OPTS = <search>/$(ICU_PATH)/lib ;
ICU_SEARCH_OPTS = <search>$(ICU_PATH)/lib ;
}
}
@ -221,17 +228,20 @@ if $(gHAS_ICU)
{
lib icucore : : <name>$(gICU_CORE_LIB) $(ICU_SEARCH_OPTS) <link>shared ;
ICU_EXTRA_SOURCE = icucore ;
explicit icucore ;
}
if $(gICU_IN_LIB)
{
lib icuin : : <name>$(gICU_IN_LIB) $(ICU_SEARCH_OPTS) <link>shared ;
ICU_EXTRA_SOURCE += icuin ;
explicit icuin ;
}
#Added by Tommy Nordgren libicudata must be linked against on Mac OS X
if $(gICU_DATA_LIB)
{
lib icudata : : <name>$(gICU_DATA_LIB) $(ICU_SEARCH_OPTS) <link>shared ;
ICU_EXTRA_SOURCE += icudata ;
explicit icudata ;
}
#End of addition by Tommy Nordgren
}
@ -267,9 +277,36 @@ lib boost_regex : ../src/$(SOURCES) $(ICU_EXTRA_SOURCE) icu_config2 icu_config
<toolset>gcc-mingw:<link>static
<toolset>gcc-cygwin:<link>static
$(BOOST_REGEX_ICU_OPTS)
<conditional>@force-shared-linking
;
shared-linking-warning-emitted = ;
# The ICU is shipped as shared libraries with dynamic runtime.
# If Boost.Regex is built against static runtime, the combination
# will not work. The below rule forces shared runtime, and
# prints an explanation.
rule force-shared-linking ( properties * )
{
if $(gHAS_ICU)
{
if <runtime-link>static in $(properties)
{
if ! $(shared-linking-warning-emitted)
{
shared-linking-warning-emitted = 1 ;
ECHO "warning: forcing runtime-link=shared for Boost.Regex" ;
ECHO "warning: this is required when using the ICU library" ;
}
}
return <runtime-link>shared ;
}
}
alias icu_options : $(ICU_EXTRA_SOURCE) : : : $(BOOST_REGEX_ICU_OPTS) ;
explicit icu_options ;
boost-install boost_regex ;

View File

@ -2008,7 +2008,7 @@ insert_recursion:
v = static_cast<int>(hash_value_from_capture_name(base, m_position));
re_brace* br = static_cast<re_brace*>(this->append_state(syntax_element_assert_backref, sizeof(re_brace)));
br->index = v;
if((*m_position != charT('>')) && (*m_position != charT('\'')) || (++m_position == m_end))
if(((*m_position != charT('>')) && (*m_position != charT('\''))) || (++m_position == m_end))
{
fail(regex_constants::error_badrepeat, m_position - m_base);
return false;

View File

@ -157,7 +157,7 @@ void scoped_static_mutex_lock::lock()
{
boost::call_once(static_mutex::m_once,&static_mutex::init);
if(0 == m_plock)
m_plock = new boost::recursive_mutex::scoped_lock(*static_mutex::m_pmutex, false);
m_plock = new boost::recursive_mutex::scoped_lock(*static_mutex::m_pmutex, boost::defer_lock);
m_plock->lock();
m_have_lock = true;
}