diff options
-rwxr-xr-x | Configure | 61 | ||||
-rw-r--r-- | Cross/config.sh-arm-linux | 2 | ||||
-rw-r--r-- | NetWare/config.wc | 2 | ||||
-rw-r--r-- | Porting/Glossary | 10 | ||||
-rw-r--r-- | Porting/config.sh | 2 | ||||
-rwxr-xr-x | config_h.SH | 18 | ||||
-rw-r--r-- | configure.com | 38 | ||||
-rw-r--r-- | plan9/config_sh.sample | 2 | ||||
-rw-r--r-- | symbian/config.sh | 2 | ||||
-rw-r--r-- | uconfig.h | 22 | ||||
-rw-r--r-- | uconfig.sh | 2 | ||||
-rw-r--r-- | uconfig64.sh | 2 | ||||
-rw-r--r-- | win32/config.ce | 2 | ||||
-rw-r--r-- | win32/config.gc | 2 | ||||
-rw-r--r-- | win32/config.vc | 2 |
15 files changed, 145 insertions, 24 deletions
@@ -845,7 +845,9 @@ d_charvspr='' d_vprintf='' d_wait4='' d_waitpid='' +d_wcscmp='' d_wcstombs='' +d_wcsxfrm='' d_wctomb='' d_writev='' dlext='' @@ -19198,10 +19200,67 @@ eval $inlibc set waitpid d_waitpid eval $inlibc +: look for wcscmp +echo " " +$cat >try.c <<'EOCP' +#include <stdio.h> +#include <wchar.h> +int main () +{ + wchar_t *s = L" "; + return (wcscmp (s, s) ? 1 : 0); + } +EOCP +set try +val="$undef" +if eval $compile; then + `$run ./try` + case "$?" in + 0) echo "A working wcscmp() found." >&4 + val="$define" ;; + *) echo "wcscmp() found, but it doesn't work" >&4 + ;; + esac +else + echo "wcscmp() NOT found." >&4 + fi +set d_wcscmp +eval $setvar +$rm_try + : see if wcstombs exists set wcstombs d_wcstombs eval $inlibc +: look for wcsxfrm +echo " " +$cat >try.c <<'EOCP' +#include <errno.h> +#include <wchar.h> +int main () +{ + wchar_t dst[4], *src = L" "; + errno = 0; + return (wcsxfrm (dst, src, 1) ? errno ? errno : 0 : 1); + } +EOCP +set try +val="$undef" +if eval $compile; then + `$run ./try` + case "$?" in + 0) echo "A working wcsxfrm() found." >&4 + val="$define" ;; + *) echo "wcsxfrm() found, but it doesn't work" >&4 + ;; + esac +else + echo "wcsxfrm() NOT found." >&4 + fi +set d_wcsxfrm +eval $setvar +$rm_try + : see if wctomb exists set wctomb d_wctomb eval $inlibc @@ -23409,7 +23468,9 @@ d_vprintf='$d_vprintf' d_vsnprintf='$d_vsnprintf' d_wait4='$d_wait4' d_waitpid='$d_waitpid' +d_wcscmp='$d_wcscmp' d_wcstombs='$d_wcstombs' +d_wcsxfrm='$d_wcsxfrm' d_wctomb='$d_wctomb' d_writev='$d_writev' d_xenix='$d_xenix' diff --git a/Cross/config.sh-arm-linux b/Cross/config.sh-arm-linux index 82821d4de6..25ea52caf5 100644 --- a/Cross/config.sh-arm-linux +++ b/Cross/config.sh-arm-linux @@ -540,7 +540,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp=''undef'' d_wcstombs='define' +d_wcsxfrm=''undef'' d_wctomb='define' d_writev='define' d_xenix='undef' diff --git a/NetWare/config.wc b/NetWare/config.wc index 5ad00a8d72..60cfd10578 100644 --- a/NetWare/config.wc +++ b/NetWare/config.wc @@ -529,7 +529,9 @@ d_vprintf='define' d_vsnprintf='undef' d_wait4='undef' d_waitpid='define' +d_wcscmp=''undef'' d_wcstombs='define' +d_wcsxfrm=''undef'' d_wctomb='define' d_writev='undef' d_xenix='undef' diff --git a/Porting/Glossary b/Porting/Glossary index cf6c2447fe..301fa66427 100644 --- a/Porting/Glossary +++ b/Porting/Glossary @@ -2503,11 +2503,21 @@ d_waitpid (d_waitpid.U): This variable conditionally defines HAS_WAITPID if waitpid() is available to wait for child process. +d_wcscmp (d_wcscmp.U): + This variable conditionally defines the HAS_WCSCMP symbol if the + wcscmp() routine is available and can be used to compare wide + character strings. + d_wcstombs (d_wcstombs.U): This variable conditionally defines the HAS_WCSTOMBS symbol, which indicates to the C program that the wcstombs() routine is available to convert wide character strings to multibyte strings. +d_wcsxfrm (d_wcsxfrm.U): + This variable conditionally defines the HAS_WCSXFRM symbol if the + wcsxfrm() routine is available and can be used to compare wide + character strings. + d_wctomb (d_wctomb.U): This variable conditionally defines the HAS_WCTOMB symbol, which indicates to the C program that the wctomb() routine is available diff --git a/Porting/config.sh b/Porting/config.sh index 11871d3833..e9d89fa496 100644 --- a/Porting/config.sh +++ b/Porting/config.sh @@ -551,7 +551,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='define' d_waitpid='define' +d_wcscmp=''undef'' d_wcstombs='define' +d_wcsxfrm=''undef'' d_wctomb='define' d_writev='define' d_xenix='undef' diff --git a/config_h.SH b/config_h.SH index b3d2cc56bd..5b38733d33 100755 --- a/config_h.SH +++ b/config_h.SH @@ -281,13 +281,13 @@ sed <<!GROK!THIS! >$CONFIG_H -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un /* HAS_MBSTOWCS: * This symbol, if defined, indicates that the mbstowcs routine is - * available to covert a multibyte string into a wide character string. + * available to convert a multibyte string into a wide character string. */ #$d_mbstowcs HAS_MBSTOWCS /**/ /* HAS_MBTOWC: * This symbol, if defined, indicates that the mbtowc routine is available - * to covert a multibyte to a wide character. + * to convert a multibyte to a wide character. */ #$d_mbtowc HAS_MBTOWC /**/ @@ -649,7 +649,7 @@ sed <<!GROK!THIS! >$CONFIG_H -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un /* HAS_WCTOMB: * This symbol, if defined, indicates that the wctomb routine is available - * to covert a wide character to a multibyte. + * to convert a wide character to a multibyte. */ #$d_wctomb HAS_WCTOMB /**/ @@ -4166,6 +4166,18 @@ sed <<!GROK!THIS! >$CONFIG_H -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un */ #$d_ustat HAS_USTAT /**/ +/* HAS_WCSCMP: + * This symbol, if defined, indicates that the wcscmp routine is + * available to compare two wide character strings. + */ +#$d_wcscmp HAS_WCSCMP /**/ + +/* HAS_WCSXFRM: + * This symbol, if defined, indicates that the wcsxfrm routine is + * available to tranform a wide character string for wcscmp(). + */ +#$d_wcsxfrm HAS_WCSXFRM /**/ + /* HAS_WRITEV: * This symbol, if defined, indicates that the writev routine is * available to do scatter writes. diff --git a/configure.com b/configure.com index 48f6105a56..a38e3edd8e 100644 --- a/configure.com +++ b/configure.com @@ -5391,44 +5391,48 @@ $! $! Dec C alone $ IF ccname .EQS. "DEC" .OR. ccname .EQS. "CXX" $ THEN +$ d_faststdio="define" +$ d_locconv="define" +$ d_mblen="define" $ d_mbstowcs="define" $ d_mbtowc="define" +$ d_mktime="define" +$ d_nl_langinfo="define" +$ d_setlocale="define" $ d_stdiobase="define" $ d_stdio_cnt_lval="define" $ d_stdio_ptr_lval="define" $ d_stdstdio="define" -$ d_faststdio="define" -$ d_wcstombs="define" -$ d_mblen="define" -$ d_mktime="define" $ d_strcoll="define" $ d_strxfrm="define" +$ d_wcscmp="undef" +$ d_wcstombs="define" +$ d_wcsxfrm="undef" $ d_wctomb="define" -$ i_locale="define" $ i_langinfo="define" -$ d_locconv="define" -$ d_nl_langinfo="define" -$ d_setlocale="define" +$ i_locale="define" $ vms_cc_type="decc" $ ELSE +$ d_faststdio="undef" +$ d_locconv="undef" +$ d_mblen="undef" $ d_mbstowcs="undef" $ d_mbtowc="undef" +$ d_mktime="undef" +$ d_nl_langinfo="undef" +$ d_setlocale="undef" $ d_stdiobase="undef" $ d_stdio_cnt_lval="undef" $ d_stdio_ptr_lval="undef" $ d_stdstdio="undef" -$ d_faststdio="undef" -$ d_wcstombs="undef" -$ d_mblen="undef" -$ d_mktime="undef" $ d_strcoll="undef" $ d_strxfrm="undef" $ d_wctomb="undef" -$ i_locale="undef" +$ d_wcscmp="undef" +$ d_wcstombs="define" +$ d_wcsxfrm="undef" $ i_langinfo="undef" -$ d_locconv="undef" -$ d_nl_langinfo="undef" -$ d_setlocale="undef" +$ i_locale="undef" $ ENDIF $ d_stdio_ptr_lval_sets_cnt="undef" $ d_stdio_ptr_lval_nochange_cnt="define" @@ -6350,7 +6354,9 @@ $ WC "d_vprintf='define'" $ WC "d_vsnprintf='" + d_vsnprintf + "'" $ WC "d_wait4='" + d_wait4 + "'" $ WC "d_waitpid='define'" +$ WC "d_wcscmp='" + d_wcscmp + "'" $ WC "d_wcstombs='" + d_wcstombs + "'" +$ WC "d_wcsxfrm='" + d_wcsxfrm + "'" $ WC "d_wctomb='" + d_wctomb + "'" $ WC "d_writev='undef'" $ WC "d_xenix='undef'" diff --git a/plan9/config_sh.sample b/plan9/config_sh.sample index 031a967b73..c5bcd6b58a 100644 --- a/plan9/config_sh.sample +++ b/plan9/config_sh.sample @@ -539,7 +539,9 @@ d_vprintf='define' d_vsnprintf='undef' d_wait4='undef' d_waitpid='define' +d_wcscmp=''undef'' d_wcstombs='define' +d_wcsxfrm=''undef'' d_wctomb='define' d_writev='define' d_xenix='undef' diff --git a/symbian/config.sh b/symbian/config.sh index 29482a2c50..e1c7d4e1c8 100644 --- a/symbian/config.sh +++ b/symbian/config.sh @@ -487,7 +487,9 @@ d_vprintf='define' d_vsnprintf='undef' d_wait4='undef' d_waitpid='undef' +d_wcscmp=''undef'' d_wcstombs='undef' +d_wcsxfrm=''undef'' d_wctomb='undef' d_writev='undef' d_xenix='undef' @@ -246,13 +246,13 @@ /* HAS_MBSTOWCS: * This symbol, if defined, indicates that the mbstowcs routine is - * available to covert a multibyte string into a wide character string. + * available to convert a multibyte string into a wide character string. */ /*#define HAS_MBSTOWCS / **/ /* HAS_MBTOWC: * This symbol, if defined, indicates that the mbtowc routine is available - * to covert a multibyte to a wide character. + * to convert a multibyte to a wide character. */ /*#define HAS_MBTOWC / **/ @@ -614,7 +614,7 @@ /* HAS_WCTOMB: * This symbol, if defined, indicates that the wctomb routine is available - * to covert a wide character to a multibyte. + * to convert a wide character to a multibyte. */ /*#define HAS_WCTOMB / **/ @@ -4131,6 +4131,18 @@ */ /*#define HAS_USTAT / **/ +/* HAS_WCSCMP: + * This symbol, if defined, indicates that the wcscmp routine is + * available to compare two wide character strings. + */ +/*#define HAS_WCSCMP / **/ + +/* HAS_WCSXFRM: + * This symbol, if defined, indicates that the wcsxfrm routine is + * available to tranform a wide character string for wcscmp(). + */ +/*#define HAS_WCSXFRM / **/ + /* HAS_WRITEV: * This symbol, if defined, indicates that the writev routine is * available to do scatter writes. @@ -4711,6 +4723,6 @@ #endif /* Generated from: - * 0c557b295352d0f05dcf3397478783eb763c947618aef92c2a0f86ba2540da40 config_h.SH - * a61a38253be27e9d2b4ff63b9f34ef9c6870a03037609f2c89840ad890a7aef8 uconfig.sh + * 06dae33599ea14bee0e39e3b22e1f685aaae36422af2c567dc1de19203950835 config_h.SH + * a350679952164b71c20f5b09afd8c2ffe982e97dddffa15031edc7584b357796 uconfig.sh * ex: set ro: */ diff --git a/uconfig.sh b/uconfig.sh index ee17861e70..2f71d73ef2 100644 --- a/uconfig.sh +++ b/uconfig.sh @@ -478,7 +478,9 @@ d_vprintf='define' d_vsnprintf='undef' d_wait4='undef' d_waitpid='undef' +d_wcscmp=''undef'' d_wcstombs='undef' +d_wcsxfrm=''undef'' d_wctomb='undef' d_writev='undef' d_xenix='undef' diff --git a/uconfig64.sh b/uconfig64.sh index f26a19d438..ba46d14f53 100644 --- a/uconfig64.sh +++ b/uconfig64.sh @@ -479,7 +479,9 @@ d_vprintf='define' d_vsnprintf='undef' d_wait4='undef' d_waitpid='undef' +d_wcscmp=''undef'' d_wcstombs='undef' +d_wcsxfrm=''undef'' d_wctomb='undef' d_writev='undef' d_xenix='undef' diff --git a/win32/config.ce b/win32/config.ce index 5177bebec6..b8a5cd641d 100644 --- a/win32/config.ce +++ b/win32/config.ce @@ -527,7 +527,9 @@ d_vprintf='define' d_vsnprintf='undef' d_wait4='undef' d_waitpid='define' +d_wcscmp=''undef'' d_wcstombs='define' +d_wcsxfrm=''undef'' d_wctomb='define' d_writev='undef' d_xenix='undef' diff --git a/win32/config.gc b/win32/config.gc index 39cdaefef7..4ad603ad8d 100644 --- a/win32/config.gc +++ b/win32/config.gc @@ -528,7 +528,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='undef' d_waitpid='define' +d_wcscmp=''undef'' d_wcstombs='define' +d_wcsxfrm=''undef'' d_wctomb='define' d_writev='undef' d_xenix='undef' diff --git a/win32/config.vc b/win32/config.vc index eef02e1453..800280456a 100644 --- a/win32/config.vc +++ b/win32/config.vc @@ -528,7 +528,9 @@ d_vprintf='define' d_vsnprintf='define' d_wait4='undef' d_waitpid='define' +d_wcscmp=''undef'' d_wcstombs='define' +d_wcsxfrm=''undef'' d_wctomb='define' d_writev='undef' d_xenix='undef' |