summaryrefslogtreecommitdiffstats
path: root/unix
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2020-12-24 12:09:33 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2020-12-24 12:09:33 (GMT)
commit67dd971e7082b24d6e1e6d70b5702dcef9cd884c (patch)
tree8e0be1152619714ff1775a6afdb412a0df1b31b3 /unix
parent5f6824ef23f3061d7070d75743c6555801aac123 (diff)
downloadtcl-67dd971e7082b24d6e1e6d70b5702dcef9cd884c.zip
tcl-67dd971e7082b24d6e1e6d70b5702dcef9cd884c.tar.gz
tcl-67dd971e7082b24d6e1e6d70b5702dcef9cd884c.tar.bz2
Fix check for broken strstr/strtoul/strtod functions: Modern C compilers don't accept signature mismatches any more.
Diffstat (limited to 'unix')
-rwxr-xr-xunix/configure6
-rw-r--r--unix/configure.in6
2 files changed, 6 insertions, 6 deletions
diff --git a/unix/configure b/unix/configure
index 788fd7f..150e02f 100755
--- a/unix/configure
+++ b/unix/configure
@@ -14712,7 +14712,7 @@ cat >>conftest.$ac_ext <<_ACEOF
#include <stdlib.h>
#include <string.h>
int main() {
- extern int strstr();
+ extern char *strstr(const char *, const char *);
exit(strstr("\0test", "test") ? 1 : 0);
}
_ACEOF
@@ -14882,7 +14882,7 @@ cat >>conftest.$ac_ext <<_ACEOF
#include <stdlib.h>
#include <string.h>
int main() {
- extern int strtoul();
+ extern unsigned long strtoul(const char *, char **, int);
char *term, *string = "0";
exit(strtoul(string,&term,0) != 0 || term != string+1);
}
@@ -15052,7 +15052,7 @@ cat >>conftest.$ac_ext <<_ACEOF
#include <stdlib.h>
#include <string.h>
int main() {
- extern double strtod();
+ extern double strtod(const char *, char **);
char *term, *string = " +69";
exit(strtod(string,&term) != 69 || term != string+4);
}
diff --git a/unix/configure.in b/unix/configure.in
index 27ad5f4..f57d3dc 100644
--- a/unix/configure.in
+++ b/unix/configure.in
@@ -278,7 +278,7 @@ AC_CHECK_FUNC(memmove, , [
#--------------------------------------------------------------------
SC_TCL_CHECK_BROKEN_FUNC(strstr, [
- extern int strstr();
+ extern char *strstr(const char *, const char *);
exit(strstr("\0test", "test") ? 1 : 0);
])
@@ -289,7 +289,7 @@ SC_TCL_CHECK_BROKEN_FUNC(strstr, [
#--------------------------------------------------------------------
SC_TCL_CHECK_BROKEN_FUNC(strtoul, [
- extern int strtoul();
+ extern unsigned long strtoul(const char *, char **, int);
char *term, *string = "0";
exit(strtoul(string,&term,0) != 0 || term != string+1);
])
@@ -300,7 +300,7 @@ SC_TCL_CHECK_BROKEN_FUNC(strtoul, [
#--------------------------------------------------------------------
SC_TCL_CHECK_BROKEN_FUNC(strtod, [
- extern double strtod();
+ extern double strtod(const char *, char **);
char *term, *string = " +69";
exit(strtod(string,&term) != 69 || term != string+4);
])