+
+# Set specific CPU overrides for atomicity_dir.
+# This can be over-ridden in GLIBCXX_ENABLE_ATOMIC_BUILTINS.
+# THIS TABLE IS SORTED. KEEP IT THAT WAY.
+if test -f ${glibcxx_srcdir}/config/${cpu_include_dir}/atomicity.h ; then
+ atomicity_dir=$cpu_include_dir
+fi
+
+
+if test -f ${glibcxx_srcdir}/config/${cpu_include_dir}/cxxabi_tweaks.h ; then
+ abi_tweaks_dir=$cpu_include_dir
+fi
+
+
+# Set any OS-dependent bits.
+# Set the os_include_dir.
+# Set the error_costants_dir.
+# Set c_model, c_compatibility here.
+# If atomic ops and/or numeric limits are OS-specific rather than
+# CPU-specifc, set those here too.
+# THIS TABLE IS SORTED. KEEP IT THAT WAY.
+case "${host_os}" in
+ aix4.[3456789]* | aix[56789]*)
+ # We set os_include_dir to os/aix only on AIX 4.3 and newer, but
+ # os/aix/atomicity.h works on earlier versions of AIX 4.*, so we
+ # explicitly duplicate the directory for 4.[<3].
+ os_include_dir="os/aix"
+ atomicity_dir="os/aix"
+ atomic_word_dir="os/aix"
+ OPT_LDFLAGS="-Wl,-G"
+ ;;
+ aix4.*)
+ os_include_dir="os/generic"
+ atomicity_dir="os/aix"
+ atomic_word_dir="os/aix"
+ ;;
+ aix*)
+ os_include_dir="os/generic"
+ atomicity_dir="cpu/generic"
+ ;;
+ bsd*)
+ # Plain BSD attempts to share FreeBSD files.
+ os_include_dir="os/bsd/freebsd"
+ ;;
+ cygwin*)
+ os_include_dir="os/newlib"
+ ;;
+ darwin | darwin[1-7] | darwin[1-7].*)
+ # On Darwin, performance is improved if libstdc++ is single-module.
+ # Up to at least 10.3.7, -flat_namespace is required for proper
+ # treatment of coalesced symbols.
+ OPT_LDFLAGS="${OPT_LDFLAGS} -Wl,-single_module -Wl,-flat_namespace"
+ os_include_dir="os/bsd/darwin"
+ ;;
+ darwin[89] | darwin[89].* | darwin[1-9][0-9]* )
+ # On Darwin, performance is improved if libstdc++ is single-module,
+ # and on 8+ compatibility is better if not -flat_namespace.
+ OPT_LDFLAGS="${OPT_LDFLAGS} -Wl,-single_module"
+ case "${host_cpu}" in
+ i[34567]86 | x86_64)
+ OPTIMIZE_CXXFLAGS="${OPTIMIZE_CXXFLAGS} -fvisibility-inlines-hidden"