<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">Hi Chandler,<div><br></div><div>I do not know if it was expected, but when I run configure one my iMac running Mavericks, I now get the following error:</div><div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking for clang... clang</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking for C compiler default output file name... a.out</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking whether the C compiler works... yes</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking whether we are cross compiling... no</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking for suffix of executables... </div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking for suffix of object files... o</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking whether we are using the GNU C compiler... yes</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking whether clang accepts -g... yes</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking for clang option to accept ISO C89... none needed</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking for clang++... clang++</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking whether we are using the GNU C++ compiler... yes</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking whether clang++ accepts -g... yes</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking how to run the C preprocessor... clang -E</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">checking whether clang works... no</div><div style="margin: 0px; font-size: 11px; font-family: Menlo;">configure: error: Selected compiler could not find or parse C++ standard library headers.  Rerun with CC=c-compiler CXX=c++-compiler ./configure ...</div></div><div><br></div><div>Specifying CC and CXX as suggested seem to fix the problem.</div><div><br></div><div>Thanks,</div><div><div apple-content-edited="true">
<div style="color: rgb(0, 0, 0); font-family: Helvetica;  font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">-Quentin</div>

</div>
<br><div><div>On Jan 15, 2014, at 11:19 AM, Chandler Carruth <<a href="mailto:chandlerc@gmail.com">chandlerc@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite">Author: chandlerc<br>Date: Wed Jan 15 13:19:13 2014<br>New Revision: 199325<br><br>URL: <a href="http://llvm.org/viewvc/llvm-project?rev=199325&view=rev">http://llvm.org/viewvc/llvm-project?rev=199325&view=rev</a><br>Log:<br>Sink the autoconf check for sufficiently modern host toolchain below the<br>enable flag that selects the C++ standard library to use with the host<br>toolchain. Otherwise we end up testing the wrong config.<br><br>I'm not really happy about this placement, but its pragmatic and should<br>unblock the Apple builders.<br><br>Modified:<br>    llvm/trunk/autoconf/configure.ac<br>    llvm/trunk/configure<br><br>Modified: llvm/trunk/autoconf/configure.ac<br>URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/autoconf/configure.ac?rev=199325&r1=199324&r2=199325&view=diff">http://llvm.org/viewvc/llvm-project/llvm/trunk/autoconf/configure.ac?rev=199325&r1=199324&r2=199325&view=diff</a><br>==============================================================================<br>--- llvm/trunk/autoconf/configure.ac (original)<br>+++ llvm/trunk/autoconf/configure.ac Wed Jan 15 13:19:13 2014<br>@@ -115,81 +115,6 @@ AC_COMPILE_IFELSE([AC_LANG_SOURCE([[#if<br> AC_LANG_POP([C++])<br> AC_MSG_RESULT([${llvm_cv_cxx_compiler}])<br><br>-dnl Check both GCC and Clang for sufficiently modern versions. These checks can<br>-dnl be bypassed by passing a flag if necessary on a platform.<br>-AC_ARG_ENABLE(compiler-version-checks,<br>-              AS_HELP_STRING([--enable-compiler-version-checks],<br>-                             [Check the version of the host compiler (default is YES)]),,<br>-                             enableval=default)<br>-case "$enableval" in<br>-  no)<br>-    ;;<br>-  yes|default)<br>-    AC_LANG_PUSH([C++])<br>-    case "$llvm_cv_cxx_compiler" in<br>-    clang)<br>-      AC_MSG_CHECKING([whether Clang is new enough])<br>-      AC_COMPILE_IFELSE([AC_LANG_SOURCE([[<br>-#if __clang_major__ < 3 || (__clang_major__ == 3 && __clang_minor__ < 1)<br>-#error This version of Clang is too old to build LLVM<br>-#endif<br>-]])],<br>-          [AC_MSG_RESULT([yes])],<br>-          [AC_MSG_RESULT([no])<br>-           AC_MSG_ERROR([<br>-The selected Clang compiler is not new enough to build LLVM. Please upgrade to<br>-Clang 3.1. You may pass --disable-compiler-version-checks to configure to<br>-bypass these sanity checks.])])<br>-<br>-      dnl Note that libstdc++4.6 is known broken for C++11 builds. The errors<br>-      dnl are sometimes deeply confusing though. Here we test for an obvious<br>-      dnl incomplete feature in 4.6's standard library that was completed in<br>-      dnl 4.7's.<br>-      AC_MSG_CHECKING([whether Clang will select a modern C++ standard library])<br>-      llvm_cv_old_cxxflags="$CXXFLAGS"<br>-      CXXFLAGS="$CXXFLAGS -std=c++0x"<br>-      AC_LINK_IFELSE([AC_LANG_SOURCE([[<br>-#include <atomic><br>-std::atomic<float> x(0.0f);<br>-int main() { return (float)x; }<br>-]])],<br>-          [AC_MSG_RESULT([yes])],<br>-          [AC_MSG_RESULT([no])<br>-           AC_MSG_ERROR([<br>-We detected a missing feature in the standard C++ library that was known to be<br>-missing in libstdc++4.6 and implemented in libstdc++4.7. There are numerous<br>-C++11 problems with 4.6's library, and we don't support GCCs or libstdc++ older<br>-than 4.7. You will need to update your system and ensure Clang uses the newer<br>-standard library.<br>-<br>-If this error is incorrect or you need to force things to work, you may pass<br>-'--disable-compiler-version-checks' to configure to bypass this test.])])<br>-      CXXFLAGS="$llvm_cv_old_cxxflags"<br>-      ;;<br>-    gcc)<br>-      AC_MSG_CHECKING([whether GCC is new enough])<br>-      AC_COMPILE_IFELSE([AC_LANG_SOURCE([[<br>-#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 7)<br>-#error This version of GCC is too old to build LLVM<br>-#endif<br>-]])],<br>-          [AC_MSG_RESULT([yes])],<br>-          [AC_MSG_RESULT([no])<br>-           AC_MSG_ERROR([<br>-The selected GCC C++ compiler is not new enough to build LLVM. Please upgrade<br>-to GCC 4.7. You may pass --disable-compiler-version-checks to configure to<br>-bypass these sanity checks.])])<br>-      ;;<br>-    unknown)<br>-      ;;<br>-    esac<br>-    AC_LANG_POP([C++])<br>-    ;;<br>-  *)<br>-    AC_MSG_ERROR([Invalid setting for --enable-compiler-version-checks. Use "yes" or "no"])<br>-    ;;<br>-esac<br>-<br> dnl Configure all of the projects present in our source tree. While we could<br> dnl just AC_CONFIG_SUBDIRS on the set of directories in projects that have a<br> dnl configure script, that usage of the AC_CONFIG_SUBDIRS macro is deprecated.<br>@@ -582,6 +507,83 @@ case "$enableval" in<br>   *) AC_MSG_ERROR([Invalid setting for --enable-libcpp. Use "yes" or "no"]) ;;<br> esac<br><br>+dnl Check both GCC and Clang for sufficiently modern versions. These checks can<br>+dnl be bypassed by passing a flag if necessary on a platform. We have to do<br>+dnl these checks here so that we have the configuration of the standard C++<br>+dnl library finished.<br>+AC_ARG_ENABLE(compiler-version-checks,<br>+              AS_HELP_STRING([--enable-compiler-version-checks],<br>+                             [Check the version of the host compiler (default is YES)]),,<br>+                             enableval=default)<br>+case "$enableval" in<br>+  no)<br>+    ;;<br>+  yes|default)<br>+    AC_LANG_PUSH([C++])<br>+    case "$llvm_cv_cxx_compiler" in<br>+    clang)<br>+      AC_MSG_CHECKING([whether Clang is new enough])<br>+      AC_COMPILE_IFELSE([AC_LANG_SOURCE([[<br>+#if __clang_major__ < 3 || (__clang_major__ == 3 && __clang_minor__ < 1)<br>+#error This version of Clang is too old to build LLVM<br>+#endif<br>+]])],<br>+          [AC_MSG_RESULT([yes])],<br>+          [AC_MSG_RESULT([no])<br>+           AC_MSG_ERROR([<br>+The selected Clang compiler is not new enough to build LLVM. Please upgrade to<br>+Clang 3.1. You may pass --disable-compiler-version-checks to configure to<br>+bypass these sanity checks.])])<br>+<br>+      dnl Note that libstdc++4.6 is known broken for C++11 builds. The errors<br>+      dnl are sometimes deeply confusing though. Here we test for an obvious<br>+      dnl incomplete feature in 4.6's standard library that was completed in<br>+      dnl 4.7's.<br>+      AC_MSG_CHECKING([whether Clang will select a modern C++ standard library])<br>+      llvm_cv_old_cxxflags="$CXXFLAGS"<br>+      CXXFLAGS="$CXXFLAGS -std=c++0x"<br>+      AC_LINK_IFELSE([AC_LANG_SOURCE([[<br>+#include <atomic><br>+std::atomic<float> x(0.0f);<br>+int main() { return (float)x; }<br>+]])],<br>+          [AC_MSG_RESULT([yes])],<br>+          [AC_MSG_RESULT([no])<br>+           AC_MSG_ERROR([<br>+We detected a missing feature in the standard C++ library that was known to be<br>+missing in libstdc++4.6 and implemented in libstdc++4.7. There are numerous<br>+C++11 problems with 4.6's library, and we don't support GCCs or libstdc++ older<br>+than 4.7. You will need to update your system and ensure Clang uses the newer<br>+standard library.<br>+<br>+If this error is incorrect or you need to force things to work, you may pass<br>+'--disable-compiler-version-checks' to configure to bypass this test.])])<br>+      CXXFLAGS="$llvm_cv_old_cxxflags"<br>+      ;;<br>+    gcc)<br>+      AC_MSG_CHECKING([whether GCC is new enough])<br>+      AC_COMPILE_IFELSE([AC_LANG_SOURCE([[<br>+#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 7)<br>+#error This version of GCC is too old to build LLVM<br>+#endif<br>+]])],<br>+          [AC_MSG_RESULT([yes])],<br>+          [AC_MSG_RESULT([no])<br>+           AC_MSG_ERROR([<br>+The selected GCC C++ compiler is not new enough to build LLVM. Please upgrade<br>+to GCC 4.7. You may pass --disable-compiler-version-checks to configure to<br>+bypass these sanity checks.])])<br>+      ;;<br>+    unknown)<br>+      ;;<br>+    esac<br>+    AC_LANG_POP([C++])<br>+    ;;<br>+  *)<br>+    AC_MSG_ERROR([Invalid setting for --enable-compiler-version-checks. Use "yes" or "no"])<br>+    ;;<br>+esac<br>+<br> dnl --enable-cxx11 : check whether or not to use -std=c++11 on the command line<br> AC_ARG_ENABLE(cxx11,<br>               AS_HELP_STRING([--enable-cxx11],<br><br>Modified: llvm/trunk/configure<br>URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/configure?rev=199325&r1=199324&r2=199325&view=diff">http://llvm.org/viewvc/llvm-project/llvm/trunk/configure?rev=199325&r1=199324&r2=199325&view=diff</a><br>==============================================================================<br>--- llvm/trunk/configure (original)<br>+++ llvm/trunk/configure Wed Jan 15 13:19:13 2014<br>@@ -1395,11 +1395,11 @@ if test -n "$ac_init_help"; then<br> Optional Features:<br>   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)<br>   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]<br>+  --enable-polly          Use polly if available (default is YES)<br>+  --enable-libcpp         Use libc++ if available (default is NO)<br>   --enable-compiler-version-checks<br>                           Check the version of the host compiler (default is<br>                           YES)<br>-  --enable-polly          Use polly if available (default is YES)<br>-  --enable-libcpp         Use libc++ if available (default is NO)<br>   --enable-cxx11          Use c++11 if available (default is NO)<br>   --enable-split-dwarf    Use split-dwarf if available (default is NO)<br>   --enable-clang-arcmt    Enable building of clang ARCMT (default is YES)<br>@@ -3702,340 +3702,82 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu<br> { echo "$as_me:$LINENO: result: ${llvm_cv_cxx_compiler}" >&5<br> echo "${ECHO_T}${llvm_cv_cxx_compiler}" >&6; }<br><br>-# Check whether --enable-compiler-version-checks was given.<br>-if test "${enable_compiler_version_checks+set}" = set; then<br>-  enableval=$enable_compiler_version_checks;<br>-else<br>-  enableval=default<br>-fi<br><br>-case "$enableval" in<br>-  no)<br>-    ;;<br>-  yes|default)<br>-    ac_ext=cpp<br>-ac_cpp='$CXXCPP $CPPFLAGS'<br>-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'<br>-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'<br>-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu<br><br>-    case "$llvm_cv_cxx_compiler" in<br>-    clang)<br>-      { echo "$as_me:$LINENO: checking whether Clang is new enough" >&5<br>-echo $ECHO_N "checking whether Clang is new enough... $ECHO_C" >&6; }<br>-      cat >conftest.$ac_ext <<_ACEOF<br>-/* confdefs.h.  */<br>-_ACEOF<br>-cat confdefs.h >>conftest.$ac_ext<br>-cat >>conftest.$ac_ext <<_ACEOF<br>-/* end confdefs.h.  */<br>+if test -d ${srcdir}/projects/test-suite ; then<br>+  subdirs="$subdirs projects/test-suite"<br><br>-#if __clang_major__ < 3 || (__clang_major__ == 3 && __clang_minor__ < 1)<br>-#error This version of Clang is too old to build LLVM<br>-#endif<br>+fi<br><br>-_ACEOF<br>-rm -f conftest.$ac_objext<br>-if { (ac_try="$ac_compile"<br>-case "(($ac_try" in<br>-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>-  *) ac_try_echo=$ac_try;;<br>-esac<br>-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>-  (eval "$ac_compile") 2>conftest.er1<br>-  ac_status=$?<br>-  grep -v '^ *+' conftest.er1 >conftest.err<br>-  rm -f conftest.er1<br>-  cat conftest.err >&5<br>-  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>-  (exit $ac_status); } &&<br>-<span class="Apple-tab-span" style="white-space:pre">       </span> { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'<br>-  { (case "(($ac_try" in<br>-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>-  *) ac_try_echo=$ac_try;;<br>-esac<br>-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>-  (eval "$ac_try") 2>&5<br>-  ac_status=$?<br>-  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>-  (exit $ac_status); }; } &&<br>-<span class="Apple-tab-span" style="white-space:pre">        </span> { ac_try='test -s conftest.$ac_objext'<br>-  { (case "(($ac_try" in<br>-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>-  *) ac_try_echo=$ac_try;;<br>-esac<br>-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>-  (eval "$ac_try") 2>&5<br>-  ac_status=$?<br>-  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>-  (exit $ac_status); }; }; then<br>-  { echo "$as_me:$LINENO: result: yes" >&5<br>-echo "${ECHO_T}yes" >&6; }<br>-else<br>-  echo "$as_me: failed program was:" >&5<br>-sed 's/^/| /' conftest.$ac_ext >&5<br>+if test -d ${srcdir}/projects/llvm-test ; then<br>+  subdirs="$subdirs projects/llvm-test"<br><br>-<span class="Apple-tab-span" style="white-space:pre">  </span>{ echo "$as_me:$LINENO: result: no" >&5<br>-echo "${ECHO_T}no" >&6; }<br>-           { { echo "$as_me:$LINENO: error:<br>-The selected Clang compiler is not new enough to build LLVM. Please upgrade to<br>-Clang 3.1. You may pass --disable-compiler-version-checks to configure to<br>-bypass these sanity checks." >&5<br>-echo "$as_me: error:<br>-The selected Clang compiler is not new enough to build LLVM. Please upgrade to<br>-Clang 3.1. You may pass --disable-compiler-version-checks to configure to<br>-bypass these sanity checks." >&2;}<br>-   { (exit 1); exit 1; }; }<br> fi<br><br>-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext<br>+if test -d ${srcdir}/projects/poolalloc ; then<br>+  subdirs="$subdirs projects/poolalloc"<br><br>-                              { echo "$as_me:$LINENO: checking whether Clang will select a modern C++ standard library" >&5<br>-echo $ECHO_N "checking whether Clang will select a modern C++ standard library... $ECHO_C" >&6; }<br>-      llvm_cv_old_cxxflags="$CXXFLAGS"<br>-      CXXFLAGS="$CXXFLAGS -std=c++0x"<br>-      cat >conftest.$ac_ext <<_ACEOF<br>-/* confdefs.h.  */<br>-_ACEOF<br>-cat confdefs.h >>conftest.$ac_ext<br>-cat >>conftest.$ac_ext <<_ACEOF<br>-/* end confdefs.h.  */<br>+fi<br><br>-#include <atomic><br>-std::atomic<float> x(0.0f);<br>-int main() { return (float)x; }<br>+if test -d ${srcdir}/projects/llvm-poolalloc ; then<br>+  subdirs="$subdirs projects/llvm-poolalloc"<br><br>-_ACEOF<br>-rm -f conftest.$ac_objext conftest$ac_exeext<br>-if { (ac_try="$ac_link"<br>-case "(($ac_try" in<br>-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>-  *) ac_try_echo=$ac_try;;<br>-esac<br>-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>-  (eval "$ac_link") 2>conftest.er1<br>-  ac_status=$?<br>-  grep -v '^ *+' conftest.er1 >conftest.err<br>-  rm -f conftest.er1<br>-  cat conftest.err >&5<br>-  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>-  (exit $ac_status); } &&<br>-<span class="Apple-tab-span" style="white-space:pre">   </span> { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'<br>-  { (case "(($ac_try" in<br>-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>-  *) ac_try_echo=$ac_try;;<br>-esac<br>-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>-  (eval "$ac_try") 2>&5<br>-  ac_status=$?<br>-  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>-  (exit $ac_status); }; } &&<br>-<span class="Apple-tab-span" style="white-space:pre">        </span> { ac_try='test -s conftest$ac_exeext'<br>-  { (case "(($ac_try" in<br>-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>-  *) ac_try_echo=$ac_try;;<br>-esac<br>-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>-  (eval "$ac_try") 2>&5<br>-  ac_status=$?<br>-  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>-  (exit $ac_status); }; }; then<br>-  { echo "$as_me:$LINENO: result: yes" >&5<br>-echo "${ECHO_T}yes" >&6; }<br>+fi<br>+<br>+for i in `ls ${srcdir}/projects`<br>+do<br>+  if test -d ${srcdir}/projects/${i} ; then<br>+    case ${i} in<br>+      sample)       subdirs="$subdirs projects/sample"<br>+    ;;<br>+      safecode)     subdirs="$subdirs projects/safecode"<br>+ ;;<br>+      compiler-rt)       ;;<br>+      test-suite)     ;;<br>+      llvm-test)      ;;<br>+      poolalloc)      ;;<br>+      llvm-poolalloc) ;;<br>+      *)<br>+        { echo "$as_me:$LINENO: WARNING: Unknown project (${i}) won't be configured automatically" >&5<br>+echo "$as_me: WARNING: Unknown project (${i}) won't be configured automatically" >&2;}<br>+        ;;<br>+    esac<br>+  fi<br>+done<br>+<br>+# Check whether --enable-polly was given.<br>+if test "${enable_polly+set}" = set; then<br>+  enableval=$enable_polly;<br> else<br>-  echo "$as_me: failed program was:" >&5<br>-sed 's/^/| /' conftest.$ac_ext >&5<br>+  enableval=default<br>+fi<br><br>-<span class="Apple-tab-span" style="white-space:pre">    </span>{ echo "$as_me:$LINENO: result: no" >&5<br>-echo "${ECHO_T}no" >&6; }<br>-           { { echo "$as_me:$LINENO: error:<br>-We detected a missing feature in the standard C++ library that was known to be<br>-missing in libstdc++4.6 and implemented in libstdc++4.7. There are numerous<br>-C++11 problems with 4.6's library, and we don't support GCCs or libstdc++ older<br>-than 4.7. You will need to update your system and ensure Clang uses the newer<br>-standard library.<br>+case "$enableval" in<br>+  yes) ENABLE_POLLY=1<br>+ ;;<br>+  no)  ENABLE_POLLY=0<br>+ ;;<br>+  default) ENABLE_POLLY=1<br>+ ;;<br>+  *) { { echo "$as_me:$LINENO: error: Invalid setting for --enable-polly. Use \"yes\" or \"no\"" >&5<br>+echo "$as_me: error: Invalid setting for --enable-polly. Use \"yes\" or \"no\"" >&2;}<br>+   { (exit 1); exit 1; }; } ;;<br>+esac<br><br>-If this error is incorrect or you need to force things to work, you may pass<br>-'--disable-compiler-version-checks' to configure to bypass this test." >&5<br>-echo "$as_me: error:<br>-We detected a missing feature in the standard C++ library that was known to be<br>-missing in libstdc++4.6 and implemented in libstdc++4.7. There are numerous<br>-C++11 problems with 4.6's library, and we don't support GCCs or libstdc++ older<br>-than 4.7. You will need to update your system and ensure Clang uses the newer<br>-standard library.<br><br>-If this error is incorrect or you need to force things to work, you may pass<br>-'--disable-compiler-version-checks' to configure to bypass this test." >&2;}<br>-   { (exit 1); exit 1; }; }<br>+if (test -d ${srcdir}/tools/polly) && (test $ENABLE_POLLY -eq 1) ; then<br>+  LLVM_HAS_POLLY=1<br>+<br>+  subdirs="$subdirs tools/polly"<br>+<br> fi<br><br>-rm -f core conftest.err conftest.$ac_objext \<br>-      conftest$ac_exeext conftest.$ac_ext<br>-      CXXFLAGS="$llvm_cv_old_cxxflags"<br>-      ;;<br>-    gcc)<br>-      { echo "$as_me:$LINENO: checking whether GCC is new enough" >&5<br>-echo $ECHO_N "checking whether GCC is new enough... $ECHO_C" >&6; }<br>-      cat >conftest.$ac_ext <<_ACEOF<br>-/* confdefs.h.  */<br>-_ACEOF<br>-cat confdefs.h >>conftest.$ac_ext<br>-cat >>conftest.$ac_ext <<_ACEOF<br>-/* end confdefs.h.  */<br><br>-#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 7)<br>-#error This version of GCC is too old to build LLVM<br>-#endif<br>-<br>-_ACEOF<br>-rm -f conftest.$ac_objext<br>-if { (ac_try="$ac_compile"<br>-case "(($ac_try" in<br>-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>-  *) ac_try_echo=$ac_try;;<br>-esac<br>-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>-  (eval "$ac_compile") 2>conftest.er1<br>-  ac_status=$?<br>-  grep -v '^ *+' conftest.er1 >conftest.err<br>-  rm -f conftest.er1<br>-  cat conftest.err >&5<br>-  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>-  (exit $ac_status); } &&<br>-<span class="Apple-tab-span" style="white-space:pre"> </span> { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'<br>-  { (case "(($ac_try" in<br>-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>-  *) ac_try_echo=$ac_try;;<br>-esac<br>-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>-  (eval "$ac_try") 2>&5<br>-  ac_status=$?<br>-  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>-  (exit $ac_status); }; } &&<br>-<span class="Apple-tab-span" style="white-space:pre">        </span> { ac_try='test -s conftest.$ac_objext'<br>-  { (case "(($ac_try" in<br>-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>-  *) ac_try_echo=$ac_try;;<br>-esac<br>-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>-  (eval "$ac_try") 2>&5<br>-  ac_status=$?<br>-  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>-  (exit $ac_status); }; }; then<br>-  { echo "$as_me:$LINENO: result: yes" >&5<br>-echo "${ECHO_T}yes" >&6; }<br>-else<br>-  echo "$as_me: failed program was:" >&5<br>-sed 's/^/| /' conftest.$ac_ext >&5<br>-<br>-<span class="Apple-tab-span" style="white-space:pre">   </span>{ echo "$as_me:$LINENO: result: no" >&5<br>-echo "${ECHO_T}no" >&6; }<br>-           { { echo "$as_me:$LINENO: error:<br>-The selected GCC C++ compiler is not new enough to build LLVM. Please upgrade<br>-to GCC 4.7. You may pass --disable-compiler-version-checks to configure to<br>-bypass these sanity checks." >&5<br>-echo "$as_me: error:<br>-The selected GCC C++ compiler is not new enough to build LLVM. Please upgrade<br>-to GCC 4.7. You may pass --disable-compiler-version-checks to configure to<br>-bypass these sanity checks." >&2;}<br>-   { (exit 1); exit 1; }; }<br>-fi<br>-<br>-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext<br>-      ;;<br>-    unknown)<br>-      ;;<br>-    esac<br>-    ac_ext=c<br>-ac_cpp='$CPP $CPPFLAGS'<br>-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'<br>-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'<br>-ac_compiler_gnu=$ac_cv_c_compiler_gnu<br>-<br>-    ;;<br>-  *)<br>-    { { echo "$as_me:$LINENO: error: Invalid setting for --enable-compiler-version-checks. Use \"yes\" or \"no\"" >&5<br>-echo "$as_me: error: Invalid setting for --enable-compiler-version-checks. Use \"yes\" or \"no\"" >&2;}<br>-   { (exit 1); exit 1; }; }<br>-    ;;<br>-esac<br>-<br>-<br>-<br>-if test -d ${srcdir}/projects/test-suite ; then<br>-  subdirs="$subdirs projects/test-suite"<br>-<br>-fi<br>-<br>-if test -d ${srcdir}/projects/llvm-test ; then<br>-  subdirs="$subdirs projects/llvm-test"<br>-<br>-fi<br>-<br>-if test -d ${srcdir}/projects/poolalloc ; then<br>-  subdirs="$subdirs projects/poolalloc"<br>-<br>-fi<br>-<br>-if test -d ${srcdir}/projects/llvm-poolalloc ; then<br>-  subdirs="$subdirs projects/llvm-poolalloc"<br>-<br>-fi<br>-<br>-for i in `ls ${srcdir}/projects`<br>-do<br>-  if test -d ${srcdir}/projects/${i} ; then<br>-    case ${i} in<br>-      sample)       subdirs="$subdirs projects/sample"<br>-    ;;<br>-      safecode)     subdirs="$subdirs projects/safecode"<br>- ;;<br>-      compiler-rt)       ;;<br>-      test-suite)     ;;<br>-      llvm-test)      ;;<br>-      poolalloc)      ;;<br>-      llvm-poolalloc) ;;<br>-      *)<br>-        { echo "$as_me:$LINENO: WARNING: Unknown project (${i}) won't be configured automatically" >&5<br>-echo "$as_me: WARNING: Unknown project (${i}) won't be configured automatically" >&2;}<br>-        ;;<br>-    esac<br>-  fi<br>-done<br>-<br>-# Check whether --enable-polly was given.<br>-if test "${enable_polly+set}" = set; then<br>-  enableval=$enable_polly;<br>-else<br>-  enableval=default<br>-fi<br>-<br>-case "$enableval" in<br>-  yes) ENABLE_POLLY=1<br>- ;;<br>-  no)  ENABLE_POLLY=0<br>- ;;<br>-  default) ENABLE_POLLY=1<br>- ;;<br>-  *) { { echo "$as_me:$LINENO: error: Invalid setting for --enable-polly. Use \"yes\" or \"no\"" >&5<br>-echo "$as_me: error: Invalid setting for --enable-polly. Use \"yes\" or \"no\"" >&2;}<br>-   { (exit 1); exit 1; }; } ;;<br>-esac<br>-<br>-<br>-if (test -d ${srcdir}/tools/polly) && (test $ENABLE_POLLY -eq 1) ; then<br>-  LLVM_HAS_POLLY=1<br>-<br>-  subdirs="$subdirs tools/polly"<br>-<br>-fi<br>-<br>-<br>-# Make sure we can run config.sub.<br>-$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||<br>-  { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5<br>-echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}<br>-   { (exit 1); exit 1; }; }<br>+# Make sure we can run config.sub.<br>+$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||<br>+  { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5<br>+echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}<br>+   { (exit 1); exit 1; }; }<br><br> { echo "$as_me:$LINENO: checking build system type" >&5<br> echo $ECHO_N "checking build system type... $ECHO_C" >&6; }<br>@@ -4790,6 +4532,264 @@ echo "$as_me: error: Invalid setting for<br>    { (exit 1); exit 1; }; } ;;<br> esac<br><br>+# Check whether --enable-compiler-version-checks was given.<br>+if test "${enable_compiler_version_checks+set}" = set; then<br>+  enableval=$enable_compiler_version_checks;<br>+else<br>+  enableval=default<br>+fi<br>+<br>+case "$enableval" in<br>+  no)<br>+    ;;<br>+  yes|default)<br>+    ac_ext=cpp<br>+ac_cpp='$CXXCPP $CPPFLAGS'<br>+ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'<br>+ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'<br>+ac_compiler_gnu=$ac_cv_cxx_compiler_gnu<br>+<br>+    case "$llvm_cv_cxx_compiler" in<br>+    clang)<br>+      { echo "$as_me:$LINENO: checking whether Clang is new enough" >&5<br>+echo $ECHO_N "checking whether Clang is new enough... $ECHO_C" >&6; }<br>+      cat >conftest.$ac_ext <<_ACEOF<br>+/* confdefs.h.  */<br>+_ACEOF<br>+cat confdefs.h >>conftest.$ac_ext<br>+cat >>conftest.$ac_ext <<_ACEOF<br>+/* end confdefs.h.  */<br>+<br>+#if __clang_major__ < 3 || (__clang_major__ == 3 && __clang_minor__ < 1)<br>+#error This version of Clang is too old to build LLVM<br>+#endif<br>+<br>+_ACEOF<br>+rm -f conftest.$ac_objext<br>+if { (ac_try="$ac_compile"<br>+case "(($ac_try" in<br>+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>+  *) ac_try_echo=$ac_try;;<br>+esac<br>+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>+  (eval "$ac_compile") 2>conftest.er1<br>+  ac_status=$?<br>+  grep -v '^ *+' conftest.er1 >conftest.err<br>+  rm -f conftest.er1<br>+  cat conftest.err >&5<br>+  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>+  (exit $ac_status); } &&<br>+<span class="Apple-tab-span" style="white-space:pre">     </span> { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'<br>+  { (case "(($ac_try" in<br>+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>+  *) ac_try_echo=$ac_try;;<br>+esac<br>+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>+  (eval "$ac_try") 2>&5<br>+  ac_status=$?<br>+  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>+  (exit $ac_status); }; } &&<br>+<span class="Apple-tab-span" style="white-space:pre">        </span> { ac_try='test -s conftest.$ac_objext'<br>+  { (case "(($ac_try" in<br>+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>+  *) ac_try_echo=$ac_try;;<br>+esac<br>+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>+  (eval "$ac_try") 2>&5<br>+  ac_status=$?<br>+  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>+  (exit $ac_status); }; }; then<br>+  { echo "$as_me:$LINENO: result: yes" >&5<br>+echo "${ECHO_T}yes" >&6; }<br>+else<br>+  echo "$as_me: failed program was:" >&5<br>+sed 's/^/| /' conftest.$ac_ext >&5<br>+<br>+<span class="Apple-tab-span" style="white-space:pre">   </span>{ echo "$as_me:$LINENO: result: no" >&5<br>+echo "${ECHO_T}no" >&6; }<br>+           { { echo "$as_me:$LINENO: error:<br>+The selected Clang compiler is not new enough to build LLVM. Please upgrade to<br>+Clang 3.1. You may pass --disable-compiler-version-checks to configure to<br>+bypass these sanity checks." >&5<br>+echo "$as_me: error:<br>+The selected Clang compiler is not new enough to build LLVM. Please upgrade to<br>+Clang 3.1. You may pass --disable-compiler-version-checks to configure to<br>+bypass these sanity checks." >&2;}<br>+   { (exit 1); exit 1; }; }<br>+fi<br>+<br>+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext<br>+<br>+                              { echo "$as_me:$LINENO: checking whether Clang will select a modern C++ standard library" >&5<br>+echo $ECHO_N "checking whether Clang will select a modern C++ standard library... $ECHO_C" >&6; }<br>+      llvm_cv_old_cxxflags="$CXXFLAGS"<br>+      CXXFLAGS="$CXXFLAGS -std=c++0x"<br>+      cat >conftest.$ac_ext <<_ACEOF<br>+/* confdefs.h.  */<br>+_ACEOF<br>+cat confdefs.h >>conftest.$ac_ext<br>+cat >>conftest.$ac_ext <<_ACEOF<br>+/* end confdefs.h.  */<br>+<br>+#include <atomic><br>+std::atomic<float> x(0.0f);<br>+int main() { return (float)x; }<br>+<br>+_ACEOF<br>+rm -f conftest.$ac_objext conftest$ac_exeext<br>+if { (ac_try="$ac_link"<br>+case "(($ac_try" in<br>+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>+  *) ac_try_echo=$ac_try;;<br>+esac<br>+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>+  (eval "$ac_link") 2>conftest.er1<br>+  ac_status=$?<br>+  grep -v '^ *+' conftest.er1 >conftest.err<br>+  rm -f conftest.er1<br>+  cat conftest.err >&5<br>+  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>+  (exit $ac_status); } &&<br>+<span class="Apple-tab-span" style="white-space:pre">  </span> { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'<br>+  { (case "(($ac_try" in<br>+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>+  *) ac_try_echo=$ac_try;;<br>+esac<br>+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>+  (eval "$ac_try") 2>&5<br>+  ac_status=$?<br>+  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>+  (exit $ac_status); }; } &&<br>+<span class="Apple-tab-span" style="white-space:pre">        </span> { ac_try='test -s conftest$ac_exeext'<br>+  { (case "(($ac_try" in<br>+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>+  *) ac_try_echo=$ac_try;;<br>+esac<br>+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>+  (eval "$ac_try") 2>&5<br>+  ac_status=$?<br>+  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>+  (exit $ac_status); }; }; then<br>+  { echo "$as_me:$LINENO: result: yes" >&5<br>+echo "${ECHO_T}yes" >&6; }<br>+else<br>+  echo "$as_me: failed program was:" >&5<br>+sed 's/^/| /' conftest.$ac_ext >&5<br>+<br>+<span class="Apple-tab-span" style="white-space:pre">    </span>{ echo "$as_me:$LINENO: result: no" >&5<br>+echo "${ECHO_T}no" >&6; }<br>+           { { echo "$as_me:$LINENO: error:<br>+We detected a missing feature in the standard C++ library that was known to be<br>+missing in libstdc++4.6 and implemented in libstdc++4.7. There are numerous<br>+C++11 problems with 4.6's library, and we don't support GCCs or libstdc++ older<br>+than 4.7. You will need to update your system and ensure Clang uses the newer<br>+standard library.<br>+<br>+If this error is incorrect or you need to force things to work, you may pass<br>+'--disable-compiler-version-checks' to configure to bypass this test." >&5<br>+echo "$as_me: error:<br>+We detected a missing feature in the standard C++ library that was known to be<br>+missing in libstdc++4.6 and implemented in libstdc++4.7. There are numerous<br>+C++11 problems with 4.6's library, and we don't support GCCs or libstdc++ older<br>+than 4.7. You will need to update your system and ensure Clang uses the newer<br>+standard library.<br>+<br>+If this error is incorrect or you need to force things to work, you may pass<br>+'--disable-compiler-version-checks' to configure to bypass this test." >&2;}<br>+   { (exit 1); exit 1; }; }<br>+fi<br>+<br>+rm -f core conftest.err conftest.$ac_objext \<br>+      conftest$ac_exeext conftest.$ac_ext<br>+      CXXFLAGS="$llvm_cv_old_cxxflags"<br>+      ;;<br>+    gcc)<br>+      { echo "$as_me:$LINENO: checking whether GCC is new enough" >&5<br>+echo $ECHO_N "checking whether GCC is new enough... $ECHO_C" >&6; }<br>+      cat >conftest.$ac_ext <<_ACEOF<br>+/* confdefs.h.  */<br>+_ACEOF<br>+cat confdefs.h >>conftest.$ac_ext<br>+cat >>conftest.$ac_ext <<_ACEOF<br>+/* end confdefs.h.  */<br>+<br>+#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 7)<br>+#error This version of GCC is too old to build LLVM<br>+#endif<br>+<br>+_ACEOF<br>+rm -f conftest.$ac_objext<br>+if { (ac_try="$ac_compile"<br>+case "(($ac_try" in<br>+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>+  *) ac_try_echo=$ac_try;;<br>+esac<br>+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>+  (eval "$ac_compile") 2>conftest.er1<br>+  ac_status=$?<br>+  grep -v '^ *+' conftest.er1 >conftest.err<br>+  rm -f conftest.er1<br>+  cat conftest.err >&5<br>+  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>+  (exit $ac_status); } &&<br>+<span class="Apple-tab-span" style="white-space:pre">    </span> { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'<br>+  { (case "(($ac_try" in<br>+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>+  *) ac_try_echo=$ac_try;;<br>+esac<br>+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>+  (eval "$ac_try") 2>&5<br>+  ac_status=$?<br>+  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>+  (exit $ac_status); }; } &&<br>+<span class="Apple-tab-span" style="white-space:pre">        </span> { ac_try='test -s conftest.$ac_objext'<br>+  { (case "(($ac_try" in<br>+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;<br>+  *) ac_try_echo=$ac_try;;<br>+esac<br>+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5<br>+  (eval "$ac_try") 2>&5<br>+  ac_status=$?<br>+  echo "$as_me:$LINENO: \$? = $ac_status" >&5<br>+  (exit $ac_status); }; }; then<br>+  { echo "$as_me:$LINENO: result: yes" >&5<br>+echo "${ECHO_T}yes" >&6; }<br>+else<br>+  echo "$as_me: failed program was:" >&5<br>+sed 's/^/| /' conftest.$ac_ext >&5<br>+<br>+<span class="Apple-tab-span" style="white-space:pre">   </span>{ echo "$as_me:$LINENO: result: no" >&5<br>+echo "${ECHO_T}no" >&6; }<br>+           { { echo "$as_me:$LINENO: error:<br>+The selected GCC C++ compiler is not new enough to build LLVM. Please upgrade<br>+to GCC 4.7. You may pass --disable-compiler-version-checks to configure to<br>+bypass these sanity checks." >&5<br>+echo "$as_me: error:<br>+The selected GCC C++ compiler is not new enough to build LLVM. Please upgrade<br>+to GCC 4.7. You may pass --disable-compiler-version-checks to configure to<br>+bypass these sanity checks." >&2;}<br>+   { (exit 1); exit 1; }; }<br>+fi<br>+<br>+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext<br>+      ;;<br>+    unknown)<br>+      ;;<br>+    esac<br>+    ac_ext=c<br>+ac_cpp='$CPP $CPPFLAGS'<br>+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'<br>+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'<br>+ac_compiler_gnu=$ac_cv_c_compiler_gnu<br>+<br>+    ;;<br>+  *)<br>+    { { echo "$as_me:$LINENO: error: Invalid setting for --enable-compiler-version-checks. Use \"yes\" or \"no\"" >&5<br>+echo "$as_me: error: Invalid setting for --enable-compiler-version-checks. Use \"yes\" or \"no\"" >&2;}<br>+   { (exit 1); exit 1; }; }<br>+    ;;<br>+esac<br>+<br> # Check whether --enable-cxx11 was given.<br> if test "${enable_cxx11+set}" = set; then<br>   enableval=$enable_cxx11;<br><br><br>_______________________________________________<br>llvm-commits mailing list<br><a href="mailto:llvm-commits@cs.uiuc.edu">llvm-commits@cs.uiuc.edu</a><br>http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits<br></blockquote></div><br></div></body></html>