# HG changeset patch # User Mike Miller # Date 1456274884 28800 # Node ID fd4ff31b3eedc8b05b19f1d20557900bde5c0c1a # Parent 9a49c83cb360b72a81e422fb522ab6bc93dd3e6c build: Fix C++11 compliance detection to work with clang * prog_cxx.m4 (OCTAVE_CXX_CXX11_TEST_BODY): Const-qualify Unicode string initializations to work with stricter compilers (e.g. clang). diff -r 9a49c83cb360 -r fd4ff31b3eed m4/prog_cxx.m4 --- a/m4/prog_cxx.m4 Tue Feb 23 16:34:23 2016 -0800 +++ b/m4/prog_cxx.m4 Tue Feb 23 16:48:04 2016 -0800 @@ -318,9 +318,12 @@ std::vector> v1; } { +dnl FIXME: Octave-specific change, this feature test is modified from the +dnl original Autoconf source. The "const" type qualifier is strictly required, +dnl needed for this test to pass with clang for example. // Unicode literals - char *utf8 = u8"UTF-8 string \u2500"; - char16_t *utf16 = u"UTF-8 string \u2500"; - char32_t *utf32 = U"UTF-32 string \u2500"; + const char *utf8 = u8"UTF-8 string \u2500"; + const char16_t *utf16 = u"UTF-8 string \u2500"; + const char32_t *utf32 = U"UTF-32 string \u2500"; } ]])