OpenSDE Packages Database (without history before r20070)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

64 lines
2.6 KiB

  1. # --- SDE-COPYRIGHT-NOTE-BEGIN ---
  2. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  3. #
  4. # Filename: package/.../uclibc/pkg_patch/gcc/204-uclibc-locale-wchar_fix.patch
  5. # Copyright (C) 2009 The OpenSDE Project
  6. #
  7. # More information can be found in the files COPYING and README.
  8. #
  9. # This patch file is dual-licensed. It is available under the license the
  10. # patched project is licensed under, as long as it is an OpenSource license
  11. # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
  12. # of the GNU General Public License as published by the Free Software
  13. # Foundation; either version 2 of the License, or (at your option) any later
  14. # version.
  15. # --- SDE-COPYRIGHT-NOTE-END ---
  16. --- gcc/libstdc++-v3/config/locale/uclibc/monetary_members.cc.uclibc200_wchar~ 2006-03-10 15:32:37 +0100
  17. +++ gcc/libstdc++-v3/config/locale/uclibc/monetary_members.cc 2006-03-10 15:37:27 +0100
  18. @@ -401,7 +401,7 @@
  19. # ifdef __UCLIBC_HAS_XLOCALE__
  20. _M_data->_M_decimal_point = __cloc->decimal_point_wc;
  21. _M_data->_M_thousands_sep = __cloc->thousands_sep_wc;
  22. -# else
  23. +# elif defined __UCLIBC_HAS_LOCALE__
  24. _M_data->_M_decimal_point = __global_locale->decimal_point_wc;
  25. _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc;
  26. # endif
  27. @@ -556,7 +556,7 @@
  28. # ifdef __UCLIBC_HAS_XLOCALE__
  29. _M_data->_M_decimal_point = __cloc->decimal_point_wc;
  30. _M_data->_M_thousands_sep = __cloc->thousands_sep_wc;
  31. -# else
  32. +# elif defined __UCLIBC_HAS_LOCALE__
  33. _M_data->_M_decimal_point = __global_locale->decimal_point_wc;
  34. _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc;
  35. # endif
  36. --- gcc/libstdc++-v3/config/locale/uclibc/numeric_members.cc.uclibc200_wchar~ 2006-03-10 15:32:37 +0100
  37. +++ gcc/libstdc++-v3/config/locale/uclibc/numeric_members.cc 2006-03-10 15:37:27 +0100
  38. @@ -127,12 +127,25 @@
  39. {
  40. // Named locale.
  41. // NB: In the GNU model wchar_t is always 32 bit wide.
  42. +#ifdef __UCLIBC_MJN3_ONLY__
  43. +#warning fix this... should be numeric
  44. +#endif
  45. +#ifdef __UCLIBC__
  46. +# ifdef __UCLIBC_HAS_XLOCALE__
  47. + _M_data->_M_decimal_point = __cloc->decimal_point_wc;
  48. + _M_data->_M_thousands_sep = __cloc->thousands_sep_wc;
  49. +# elif defined __UCLIBC_HAS_LOCALE__
  50. + _M_data->_M_decimal_point = __global_locale->decimal_point_wc;
  51. + _M_data->_M_thousands_sep = __global_locale->thousands_sep_wc;
  52. +# endif
  53. +#else
  54. union { char *__s; wchar_t __w; } __u;
  55. __u.__s = __nl_langinfo_l(_NL_NUMERIC_DECIMAL_POINT_WC, __cloc);
  56. _M_data->_M_decimal_point = __u.__w;
  57. __u.__s = __nl_langinfo_l(_NL_NUMERIC_THOUSANDS_SEP_WC, __cloc);
  58. _M_data->_M_thousands_sep = __u.__w;
  59. +#endif
  60. if (_M_data->_M_thousands_sep == L'\0')
  61. _M_data->_M_grouping = "";