diff --git a/.metaconf-exclusions.txt b/.metaconf-exclusions.txt index ce9e3d565868..e8138ea8cfdb 100644 --- a/.metaconf-exclusions.txt +++ b/.metaconf-exclusions.txt @@ -24,3 +24,4 @@ I_LIMITS I_STDARG index rindex +const diff --git a/Configure b/Configure index a7fe7b011c39..6041b0bbb0ec 100755 --- a/Configure +++ b/Configure @@ -410,7 +410,6 @@ d_clearenv='' d_closedir='' d_void_closedir='' d_cmsghdr_s='' -d_const='' d_copysign='' d_copysignl='' d_cplusplus='' @@ -12054,27 +12053,6 @@ case "$d_cmsghdr_s" in *) echo "No, it doesn't." ;; esac -: check for const keyword -echo " " -echo 'Checking to see if your C compiler knows about "const"...' >&4 -$cat >const.c <<'EOCP' -typedef struct spug { int drokk; } spug; -int main() -{ - const char *foo; - const spug y = { 0 }; -} -EOCP -if $cc -c $ccflags const.c >/dev/null 2>&1 ; then - val="$define" - echo "Yup, it does." -else - val="$undef" - echo "Nope, it doesn't." -fi -set d_const -eval $setvar - : see if copysign exists set copysign d_copysign eval $inlibc @@ -19856,10 +19834,6 @@ $define) echo " " echo "Checking Berkeley DB version ..." >&4 $cat >try.c < #include #$i_stdlib I_STDLIB @@ -19950,10 +19924,6 @@ define) echo " " echo "Checking return type needed for hash for Berkeley DB ..." >&4 $cat >try.c < #include @@ -19994,10 +19964,6 @@ define) echo " " echo "Checking return type needed for prefix for Berkeley DB ..." >&4 cat >try.c < #include @@ -23843,7 +23809,6 @@ d_class='$d_class' d_clearenv='$d_clearenv' d_closedir='$d_closedir' d_cmsghdr_s='$d_cmsghdr_s' -d_const='$d_const' d_copysign='$d_copysign' d_copysignl='$d_copysignl' d_cplusplus='$d_cplusplus' diff --git a/Cross/config.sh-arm-linux b/Cross/config.sh-arm-linux index d8904ec458b7..94446dbc0c5e 100644 --- a/Cross/config.sh-arm-linux +++ b/Cross/config.sh-arm-linux @@ -144,7 +144,6 @@ d_class='undef' d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' -d_const='define' d_copysign='undef' d_copysignl='define' d_cplusplus='undef' diff --git a/Cross/config.sh-arm-linux-n770 b/Cross/config.sh-arm-linux-n770 index 34512eeec6f9..ea840d51e197 100644 --- a/Cross/config.sh-arm-linux-n770 +++ b/Cross/config.sh-arm-linux-n770 @@ -143,7 +143,6 @@ d_class='undef' d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' -d_const='define' d_copysign='undef' d_copysignl='define' d_cplusplus='undef' diff --git a/NetWare/config.wc b/NetWare/config.wc index 2bd9bff5a236..e0e880d7de83 100644 --- a/NetWare/config.wc +++ b/NetWare/config.wc @@ -131,7 +131,6 @@ d_class='undef' d_clearenv='undef' d_closedir='define' d_cmsghdr_s='undef' -d_const='define' d_copysign='undef' d_copysignl='undef' d_cplusplus='undef' diff --git a/NetWare/config_H.wc b/NetWare/config_H.wc index 63573c1c6f0f..e351e273a49c 100644 --- a/NetWare/config_H.wc +++ b/NetWare/config_H.wc @@ -68,17 +68,6 @@ */ #define HAS_CHSIZE /**/ -/* HASCONST: - * This symbol, if defined, indicates that this C compiler knows about - * the const type. There is no need to actually test for that symbol - * within your programs. The mere use of the "const" keyword will - * trigger the necessary tests. - */ -#define HASCONST /**/ -#ifndef HASCONST -#define const -#endif - /* HAS_CRYPT: * This symbol, if defined, indicates that the crypt routine is available * to encrypt passwords and the like. diff --git a/Porting/Glossary b/Porting/Glossary index e9adc57685c7..e285e52c4945 100644 --- a/Porting/Glossary +++ b/Porting/Glossary @@ -584,11 +584,6 @@ d_cmsghdr_s (d_cmsghdr_s.U): This variable conditionally defines the HAS_STRUCT_CMSGHDR symbol, which indicates that the struct cmsghdr is supported. -d_const (d_const.U): - This variable conditionally defines the HASCONST symbol, which - indicates to the C program that this C compiler knows about the - const type. - d_copysign (d_copysign.U): This variable conditionally defines the HAS_COPYSIGN symbol, which indicates to the C program that the copysign() routine is available. diff --git a/Porting/config.sh b/Porting/config.sh index 77c13a3a1865..e188fd329f51 100644 --- a/Porting/config.sh +++ b/Porting/config.sh @@ -158,7 +158,6 @@ d_class='undef' d_clearenv='define' d_closedir='define' d_cmsghdr_s='define' -d_const='define' d_copysign='define' d_copysignl='define' d_cplusplus='undef' diff --git a/Porting/config_H b/Porting/config_H index 648c12b98e6d..5619294abbee 100644 --- a/Porting/config_H +++ b/Porting/config_H @@ -1483,17 +1483,6 @@ */ #define HAS_BACKTRACE /**/ -/* HASCONST: - * This symbol, if defined, indicates that this C compiler knows about - * the const type. There is no need to actually test for that symbol - * within your programs. The mere use of the "const" keyword will - * trigger the necessary tests. - */ -#define HASCONST /**/ -#ifndef HASCONST -#define const -#endif - /* HAS_CSH: * This symbol, if defined, indicates that the C-shell exists. */ diff --git a/config_h.SH b/config_h.SH index f275932e2113..388c1fe050ab 100755 --- a/config_h.SH +++ b/config_h.SH @@ -1514,17 +1514,6 @@ sed <$CONFIG_H -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un */ #$d_backtrace HAS_BACKTRACE /**/ -/* HASCONST: - * This symbol, if defined, indicates that this C compiler knows about - * the const type. There is no need to actually test for that symbol - * within your programs. The mere use of the "const" keyword will - * trigger the necessary tests. - */ -#$d_const HASCONST /**/ -#ifndef HASCONST -#define const -#endif - /* HAS_CSH: * This symbol, if defined, indicates that the C-shell exists. */ diff --git a/configure.com b/configure.com index 5e1781d23f8e..70a80455e604 100644 --- a/configure.com +++ b/configure.com @@ -5969,7 +5969,6 @@ $ WC "d_chsize='undef'" $ WC "d_class='undef'" $ WC "d_closedir='define'" $ WC "d_cmsghdr_s='undef'" -$ WC "d_const='define'" $ WC "d_copysign='" + d_copysign + "'" $ WC "d_copysignl='define'" $ WC "d_cplusplus='" + d_cplusplus + "'" diff --git a/plan9/config.plan9 b/plan9/config.plan9 index 6129eae7e324..7a452acd0df3 100644 --- a/plan9/config.plan9 +++ b/plan9/config.plan9 @@ -110,17 +110,6 @@ */ /*#define HAS_CHSIZE / **/ -/* HASCONST: - * This symbol, if defined, indicates that this C compiler knows about - * the const type. There is no need to actually test for that symbol - * within your programs. The mere use of the "const" keyword will - * trigger the necessary tests. - */ -#define HASCONST /**/ -#ifndef HASCONST -#define const -#endif - /* HAS_CUSERID: * This symbol, if defined, indicates that the cuserid routine is * available to get character login names. diff --git a/plan9/config_h.sample b/plan9/config_h.sample index d888d07f431f..f71d55bd5370 100644 --- a/plan9/config_h.sample +++ b/plan9/config_h.sample @@ -68,17 +68,6 @@ */ /*#define HAS_CHSIZE / **/ -/* HASCONST: - * This symbol, if defined, indicates that this C compiler knows about - * the const type. There is no need to actually test for that symbol - * within your programs. The mere use of the "const" keyword will - * trigger the necessary tests. - */ -#define HASCONST /**/ -#ifndef HASCONST -#define const -#endif - /* HAS_CUSERID: * This symbol, if defined, indicates that the cuserid routine is * available to get character login names. diff --git a/plan9/config_sh.sample b/plan9/config_sh.sample index b86f5f1ef9b7..0fb93cd4ff99 100644 --- a/plan9/config_sh.sample +++ b/plan9/config_sh.sample @@ -144,7 +144,6 @@ d_class='undef' d_clearenv='undef' d_closedir='define' d_cmsghdr_s='undef' -d_const='define' d_copysign='undef' d_copysignl='undef' d_cplusplus='undef' diff --git a/symbian/config.sh b/symbian/config.sh index a7a5288ea8a5..7810dc153d9e 100644 --- a/symbian/config.sh +++ b/symbian/config.sh @@ -89,7 +89,6 @@ d_class='undef' d_clearenv='undef' d_closedir='undef' d_cmsghdr_s='undef' -d_const='define' d_copysign='undef' d_copysignl='undef' d_cplusplus='undef' diff --git a/uconfig.h b/uconfig.h index e7f8127a2733..37fed70fee0f 100644 --- a/uconfig.h +++ b/uconfig.h @@ -1479,17 +1479,6 @@ */ /*#define HAS_BACKTRACE / **/ -/* HASCONST: - * This symbol, if defined, indicates that this C compiler knows about - * the const type. There is no need to actually test for that symbol - * within your programs. The mere use of the "const" keyword will - * trigger the necessary tests. - */ -/*#define HASCONST / **/ -#ifndef HASCONST -#define const -#endif - /* HAS_CSH: * This symbol, if defined, indicates that the C-shell exists. */ @@ -5230,6 +5219,6 @@ #endif /* Generated from: - * 86429d6dea8cb2d81b30da9d916693eb4c04ebeb21969c8df6f470ac77cd5c92 config_h.SH - * fd30f4a36ebf71b0b366649cee58bb37d9d61863201e087e8f40e4ceae0abf1d uconfig.sh + * 875df2221ab768da0a87740ad45e12bbc9e3b483bfa1a913727e982350ad74cf config_h.SH + * 24ca29f990de08f8119ad2c15f060361b86fc407caab088289d7d5ac3e0f117a uconfig.sh * ex: set ro: */ diff --git a/uconfig.sh b/uconfig.sh index 6d980a517250..e87725502cf9 100644 --- a/uconfig.sh +++ b/uconfig.sh @@ -83,7 +83,6 @@ d_class='undef' d_clearenv='undef' d_closedir='define' d_cmsghdr_s='undef' -d_const='undef' d_copysign='undef' d_copysignl='undef' d_cplusplus='undef' diff --git a/uconfig64.sh b/uconfig64.sh index f806e857408b..117fa870554b 100644 --- a/uconfig64.sh +++ b/uconfig64.sh @@ -83,7 +83,6 @@ d_class='undef' d_clearenv='undef' d_closedir='define' d_cmsghdr_s='undef' -d_const='undef' d_copysign='undef' d_copysignl='undef' d_cplusplus='undef' diff --git a/win32/config.ce b/win32/config.ce index b8df115b4a83..9ab63a4da5b2 100644 --- a/win32/config.ce +++ b/win32/config.ce @@ -129,7 +129,6 @@ d_class='undef' d_clearenv='undef' d_closedir='define' d_cmsghdr_s='undef' -d_const='define' d_copysign='undef' d_copysignl='undef' d_cplusplus='undef' diff --git a/win32/config.gc b/win32/config.gc index 56f367f91d8c..ad48a737b70f 100644 --- a/win32/config.gc +++ b/win32/config.gc @@ -131,7 +131,6 @@ d_class='undef' d_clearenv='undef' d_closedir='define' d_cmsghdr_s='undef' -d_const='define' d_copysign='undef' d_copysignl='undef' d_cplusplus='undef' diff --git a/win32/config.vc b/win32/config.vc index 18812ef39a85..e44c31a143ee 100644 --- a/win32/config.vc +++ b/win32/config.vc @@ -131,7 +131,6 @@ d_class='undef' d_clearenv='undef' d_closedir='define' d_cmsghdr_s='undef' -d_const='define' d_copysign='undef' d_copysignl='undef' d_cplusplus='undef' diff --git a/win32/config_H.ce b/win32/config_H.ce index 761523b55df1..b8b8aeb93713 100644 --- a/win32/config_H.ce +++ b/win32/config_H.ce @@ -50,17 +50,6 @@ */ #define HAS_CHSIZE /**/ -/* HASCONST: - * This symbol, if defined, indicates that this C compiler knows about - * the const type. There is no need to actually test for that symbol - * within your programs. The mere use of the "const" keyword will - * trigger the necessary tests. - */ -#define HASCONST /**/ -#ifndef HASCONST -#define const -#endif - /* HAS_CUSERID: * This symbol, if defined, indicates that the cuserid routine is * available to get character login names. diff --git a/win32/config_H.gc b/win32/config_H.gc index 756d4a7cf21e..05af1d736b55 100644 --- a/win32/config_H.gc +++ b/win32/config_H.gc @@ -1474,17 +1474,6 @@ */ /*#define HAS_BACKTRACE / **/ -/* HASCONST: - * This symbol, if defined, indicates that this C compiler knows about - * the const type. There is no need to actually test for that symbol - * within your programs. The mere use of the "const" keyword will - * trigger the necessary tests. - */ -#define HASCONST /**/ -#ifndef HASCONST -#define const -#endif - /* HAS_CSH: * This symbol, if defined, indicates that the C-shell exists. */ diff --git a/win32/config_H.vc b/win32/config_H.vc index fa09da070cab..b0fc34731b15 100644 --- a/win32/config_H.vc +++ b/win32/config_H.vc @@ -1467,17 +1467,6 @@ */ /*#define HAS_BACKTRACE / **/ -/* HASCONST: - * This symbol, if defined, indicates that this C compiler knows about - * the const type. There is no need to actually test for that symbol - * within your programs. The mere use of the "const" keyword will - * trigger the necessary tests. - */ -#define HASCONST /**/ -#ifndef HASCONST -#define const -#endif - /* HAS_CSH: * This symbol, if defined, indicates that the C-shell exists. */