diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog
index 8d5312dbc9d..a2cb3d70008 100644
--- a/libstdc++-v3/ChangeLog
+++ b/libstdc++-v3/ChangeLog
@@ -1,3 +1,14 @@
+2016-03-23 Bernd Edlinger --enable-concept-checks
. When defined, performs
compile-time checking on certain template instantiations to
detect violations of the requirements of the standard. This
- is described in more detail in
+ macro has no effect for freestanding implementations.
+ This is described in more detail in
Compile Time Checks.
_GLIBCXX_ASSERTIONS
Undefined by default. When defined, enables extra error checking in
diff --git a/libstdc++-v3/doc/xml/manual/using.xml b/libstdc++-v3/doc/xml/manual/using.xml
index 6e022d5458a..231028e6b61 100644
--- a/libstdc++-v3/doc/xml/manual/using.xml
+++ b/libstdc++-v3/doc/xml/manual/using.xml
@@ -908,7 +908,8 @@ g++ -Winvalid-pch -I. -include stdc++.h -H -g -O2 hello.cc -o test.exe
--enable-concept-checks
. When defined, performs
compile-time checking on certain template instantiations to
detect violations of the requirements of the standard. This
- is described in more detail in
+ macro has no effect for freestanding implementations.
+ This is described in more detail in
Compile Time Checks.
diff --git a/libstdc++-v3/include/Makefile.am b/libstdc++-v3/include/Makefile.am
index 0b34c3c01d3..9cd6a85b9a2 100644
--- a/libstdc++-v3/include/Makefile.am
+++ b/libstdc++-v3/include/Makefile.am
@@ -1331,7 +1331,7 @@ endif
# libsupc++, so only the others and the sub-includes are copied here.
install-freestanding-headers:
$(mkinstalldirs) $(DESTDIR)${gxx_include_dir}/bits
- for file in c++0x_warning.h atomic_base.h; do \
+ for file in c++0x_warning.h atomic_base.h concept_check.h move.h; do \
$(INSTALL_DATA) ${glibcxx_srcdir}/include/bits/$${file} $(DESTDIR)${gxx_include_dir}/bits; done
$(mkinstalldirs) $(DESTDIR)${host_installdir}
for file in ${host_srcdir}/os_defines.h ${host_builddir}/c++config.h \
diff --git a/libstdc++-v3/include/Makefile.in b/libstdc++-v3/include/Makefile.in
index 3bbd3d77245..43735f9174c 100644
--- a/libstdc++-v3/include/Makefile.in
+++ b/libstdc++-v3/include/Makefile.in
@@ -1753,7 +1753,7 @@ ${pch3_output}: ${pch3_source} ${pch2_output}
# libsupc++, so only the others and the sub-includes are copied here.
install-freestanding-headers:
$(mkinstalldirs) $(DESTDIR)${gxx_include_dir}/bits
- for file in c++0x_warning.h atomic_base.h; do \
+ for file in c++0x_warning.h atomic_base.h concept_check.h move.h; do \
$(INSTALL_DATA) ${glibcxx_srcdir}/include/bits/$${file} $(DESTDIR)${gxx_include_dir}/bits; done
$(mkinstalldirs) $(DESTDIR)${host_installdir}
for file in ${host_srcdir}/os_defines.h ${host_builddir}/c++config.h \
diff --git a/libstdc++-v3/include/bits/concept_check.h b/libstdc++-v3/include/bits/concept_check.h
index 5c4fb4c3506..11092c0a781 100644
--- a/libstdc++-v3/include/bits/concept_check.h
+++ b/libstdc++-v3/include/bits/concept_check.h
@@ -41,8 +41,9 @@
// Concept-checking code is off by default unless users turn it on via
// configure options or editing c++config.h.
+// It is not supported for freestanding implementations.
-#ifndef _GLIBCXX_CONCEPT_CHECKS
+#if !defined(_GLIBCXX_CONCEPT_CHECKS) || !_GLIBCXX_HOSTED
#define __glibcxx_function_requires(...)
#define __glibcxx_class_requires(_a,_b)