Detect ICU support in Regex?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Detect ICU support in Regex?

Joseph Turian
Hi,

A program I'm writing requires that the Boost Regex library was
compiled with ICU support.

How can I determine at configure/compile time whether the Regex
library has ICU support?

I'd like to prevent the user from shooting him/herself in the foot.

    Joseph


--
http://www.cs.nyu.edu/~turian/

_______________________________________________
Boost-users mailing list
[hidden email]
http://lists.boost.org/mailman/listinfo.cgi/boost-users
Reply | Threaded
Open this post in threaded view
|

Re: Detect ICU support in Regex?

John Maddock
> A program I'm writing requires that the Boost Regex library was
> compiled with ICU support.
>
> How can I determine at configure/compile time whether the Regex
> library has ICU support?
>
> I'd like to prevent the user from shooting him/herself in the foot.

Um, you can't detect it at compile time except that, if ICU is not in the
users include path then boost/regex/icu.hpp won't compile.  You will also
get linker errors if you attempt to use ICU support and the library was
built without it.  So.... an AC_TRY_LINK in your configure script along with
a minimal test program that invokes a u32regex would do the trick.

HTH, John.

_______________________________________________
Boost-users mailing list
[hidden email]
http://lists.boost.org/mailman/listinfo.cgi/boost-users