aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaolo Carlini <pcarlini@suse.de>2007-06-28 22:58:32 +0000
committerPaolo Carlini <paolo@gcc.gnu.org>2007-06-28 22:58:32 +0000
commit1ba741304a84766aa86fdcc7008f65dcec1b2674 (patch)
tree774662485dae67e6b26c8b8d537807b71bb5c217
parente301e2c4c2b84349039d806fc1649570d8575e42 (diff)
downloadgcc-1ba741304a84766aa86fdcc7008f65dcec1b2674.zip
gcc-1ba741304a84766aa86fdcc7008f65dcec1b2674.tar.gz
gcc-1ba741304a84766aa86fdcc7008f65dcec1b2674.tar.bz2
re PR libstdc++/32509 (unable to explicitely configure with a given locale model)
2007-06-28 Paolo Carlini <pcarlini@suse.de> PR libstdc++/32509 * acinclude.m4 (GLIBCXX_ENABLE_CLOCALE): Carry out the checks involving the de_DE locale only if an auto locale config is used for a target suitable for the gnu locale model. * docs/html/install.html: Update. * configure: Regenerated. From-SVN: r126096
-rw-r--r--libstdc++-v3/ChangeLog9
-rw-r--r--libstdc++-v3/acinclude.m438
-rwxr-xr-xlibstdc++-v3/configure34
-rw-r--r--libstdc++-v3/docs/html/install.html7
4 files changed, 51 insertions, 37 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog
index 0007aaf..faaa645 100644
--- a/libstdc++-v3/ChangeLog
+++ b/libstdc++-v3/ChangeLog
@@ -1,3 +1,12 @@
+2007-06-28 Paolo Carlini <pcarlini@suse.de>
+
+ PR libstdc++/32509
+ * acinclude.m4 (GLIBCXX_ENABLE_CLOCALE): Carry out the checks
+ involving the de_DE locale only if an auto locale config is
+ used for a target suitable for the gnu locale model.
+ * docs/html/install.html: Update.
+ * configure: Regenerated.
+
2007-06-26 Benjamin Kosnik <bkoz@redhat.com>
* testsuite/util/testsuite_api.h: New.
diff --git a/libstdc++-v3/acinclude.m4 b/libstdc++-v3/acinclude.m4
index 07d5239..4b3aaa5 100644
--- a/libstdc++-v3/acinclude.m4
+++ b/libstdc++-v3/acinclude.m4
@@ -1341,21 +1341,22 @@ AC_DEFUN([GLIBCXX_ENABLE_CLOCALE], [
#endif
], enable_clocale_flag=gnu, enable_clocale_flag=generic)
- # Test for bugs early in glibc-2.2.x series
- AC_TRY_RUN([
- #define _GNU_SOURCE 1
- #include <locale.h>
- #include <string.h>
- #if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
- extern __typeof(newlocale) __newlocale;
- extern __typeof(duplocale) __duplocale;
- extern __typeof(strcoll_l) __strcoll_l;
- #endif
- int main()
- {
- const char __one[] = "Äuglein Augmen";
+ if test $enable_clocale = auto; then
+ # Test for bugs early in glibc-2.2.x series
+ AC_TRY_RUN([
+ #define _GNU_SOURCE 1
+ #include <locale.h>
+ #include <string.h>
+ #if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
+ extern __typeof(newlocale) __newlocale;
+ extern __typeof(duplocale) __duplocale;
+ extern __typeof(strcoll_l) __strcoll_l;
+ #endif
+ int main()
+ {
+ const char __one[] = "Äuglein Augmen";
const char __two[] = "Äuglein";
- int i;
+ int i;
int j;
__locale_t loc;
__locale_t loc_dup;
@@ -1364,10 +1365,11 @@ AC_DEFUN([GLIBCXX_ENABLE_CLOCALE], [
i = __strcoll_l(__one, __two, loc);
j = __strcoll_l(__one, __two, loc_dup);
return 0;
- }
- ],
- [enable_clocale_flag=gnu],[enable_clocale_flag=generic],
- [enable_clocale_flag=generic])
+ }
+ ],
+ [enable_clocale_flag=gnu],[enable_clocale_flag=generic],
+ [enable_clocale_flag=generic])
+ fi
# Set it to scream when it hurts.
ac_save_CFLAGS="$CFLAGS"
diff --git a/libstdc++-v3/configure b/libstdc++-v3/configure
index 2085f5a..d58168b 100755
--- a/libstdc++-v3/configure
+++ b/libstdc++-v3/configure
@@ -14068,8 +14068,9 @@ fi
rm -f conftest*
- # Test for bugs early in glibc-2.2.x series
- if test "$cross_compiling" = yes; then
+ if test $enable_clocale = auto; then
+ # Test for bugs early in glibc-2.2.x series
+ if test "$cross_compiling" = yes; then
enable_clocale_flag=generic
else
cat >conftest.$ac_ext <<_ACEOF
@@ -14079,19 +14080,19 @@ cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
- #define _GNU_SOURCE 1
- #include <locale.h>
- #include <string.h>
- #if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
- extern __typeof(newlocale) __newlocale;
- extern __typeof(duplocale) __duplocale;
- extern __typeof(strcoll_l) __strcoll_l;
- #endif
- int main()
- {
- const char __one[] = "Äuglein Augmen";
+ #define _GNU_SOURCE 1
+ #include <locale.h>
+ #include <string.h>
+ #if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ > 2)
+ extern __typeof(newlocale) __newlocale;
+ extern __typeof(duplocale) __duplocale;
+ extern __typeof(strcoll_l) __strcoll_l;
+ #endif
+ int main()
+ {
+ const char __one[] = "Äuglein Augmen";
const char __two[] = "Äuglein";
- int i;
+ int i;
int j;
__locale_t loc;
__locale_t loc_dup;
@@ -14100,7 +14101,7 @@ cat >>conftest.$ac_ext <<_ACEOF
i = __strcoll_l(__one, __two, loc);
j = __strcoll_l(__one, __two, loc_dup);
return 0;
- }
+ }
_ACEOF
rm -f conftest$ac_exeext
@@ -14125,6 +14126,7 @@ enable_clocale_flag=generic
fi
rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
+ fi
# Set it to scream when it hurts.
ac_save_CFLAGS="$CFLAGS"
@@ -16569,7 +16571,7 @@ ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
# Fake what AC_TRY_COMPILE does. XXX Look at redoing this new-style.
cat > conftest.$ac_ext << EOF
-#line 16572 "configure"
+#line 16574 "configure"
int main()
{
// NB: _Atomic_word not necessarily int.
diff --git a/libstdc++-v3/docs/html/install.html b/libstdc++-v3/docs/html/install.html
index 2e887b7..ab19b6f 100644
--- a/libstdc++-v3/docs/html/install.html
+++ b/libstdc++-v3/docs/html/install.html
@@ -80,9 +80,10 @@
information must be installed.
<p>
- Note that those sanity checks are also perfomed when an explicit
- --enable-clocale=gnu configure option is used: this behavior is
- new in gcc 4.2.1 and defends against misconfigurations.
+ Note however that the sanity checks involving the de_DE locale are
+ skipped when an explicit --enable-clocale=gnu configure option is
+ used: only the basic checks are carried out, defending against
+ misconfigurations.
</p>
<p>