summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorunknown <tim@localhost.polyesthetic.msg>2000-08-10 11:21:42 -0400
committerunknown <tim@localhost.polyesthetic.msg>2000-08-10 11:21:42 -0400
commit07c1b843621db9f0e7b3e1ed06ceb1256180f04a (patch)
treee053b2ec45f60431341f2d3e3b3f500218c04f4e
parentf5fa7fee9de0ed453960ada8efee6615cc77aa44 (diff)
downloadmariadb-git-07c1b843621db9f0e7b3e1ed06ceb1256180f04a.tar.gz
Automatically detect HAVE_INT_8_16_32.
Docs/manual.texi: - remove -DHAVE_INT_8_16_32 from recommended CFLAGS configure.in: - add test for int8 acconfig.h: - add HAVE_INT_8_16_32
-rw-r--r--Docs/manual.texi8
-rwxr-xr-xacconfig.h3
-rw-r--r--configure.in26
3 files changed, 31 insertions, 6 deletions
diff --git a/Docs/manual.texi b/Docs/manual.texi
index 7eebc96a540..d824c0a1c41 100644
--- a/Docs/manual.texi
+++ b/Docs/manual.texi
@@ -6687,8 +6687,8 @@ Automatic detection of @code{xlC} is missing from Autoconf, so a
@strong{MySQL}: (The example uses the IBM compiler)
@example
-shell> CC="xlc_r" CFLAGS="-ma -O3 -qstrict -DHAVE_INT_8_16_32" \
- CXX="xlC_r" CXXFLAGS="-ma -O3 -qstrict -DHAVE_INT_8_16_32" \
+shell> CC="xlc_r" CFLAGS="-ma -O3 -qstrict" \
+ CXX="xlC_r" CXXFLAGS="-ma -O3 -qstrict" \
./configure
@end example
@@ -6704,9 +6704,9 @@ handling in @code{gcc}/@code{egcs} is not thread-safe! (This is tested with
@example
shell> CC=gcc \
- CFLAGS="-DHAVE_INT_8_16_32" \
+ CFLAGS="" \
CXX=gcc \
- CXXFLAGS="-felide-constructors -fno-exceptions -fno-rtti -DHAVE_INT_8_16_32" \" \
+ CXXFLAGS="-felide-constructors -fno-exceptions -fno-rtti" \" \
./configure --prefix=/usr/local/mysql --with-debug --with-low-memory
@end example
diff --git a/acconfig.h b/acconfig.h
index 61b4e5caf8a..4e19b1c0802 100755
--- a/acconfig.h
+++ b/acconfig.h
@@ -69,6 +69,9 @@
this with 6 arguments */
#undef HAVE_GLIBC2_STYLE_GETHOSTBYNAME_R
+/* Define if int8, int16 and int32 types exist */
+#undef HAVE_INT_8_16_32
+
/* Define if we have GNU readline */
#undef HAVE_LIBREADLINE
diff --git a/configure.in b/configure.in
index 6a7c90aea8a..5550bcbe26e 100644
--- a/configure.in
+++ b/configure.in
@@ -580,6 +580,28 @@ LIBS_AFTER_SOCKET=$LIBS
LIBS="$LIBS_BEFORE_SOCKET $LIBS_SOCKET $LIBS_AFTER_SOCKET"
NON_THREADED_CLIENT_LIBS="$LIBS"
+AC_MSG_CHECKING([for int8])
+AC_TRY_RUN([
+#ifdef HAVE_STDLIB_H
+#include <stdlib.h>
+#endif
+
+#ifdef HAVE_STDDEF_H
+#include <stddef.h>
+#endif
+
+#ifdef HAVE_SYS_TYPES_H
+#include <sys/types.h>
+#endif
+
+int main()
+{
+ int8 i;
+ return 0;
+}
+], AC_DEFINE(HAVE_INT_8_16_32) AC_MSG_RESULT([yes]), AC_MSG_RESULT([no])
+)
+
#
# Some system specific hacks
#
@@ -662,8 +684,8 @@ case $SYSTEM_TYPE in
;;
*aix4.3*)
echo "Adding defines for AIX"
- CFLAGS="$CFLAGS -DHAVE_INT_8_16_32 -DUNDEF_HAVE_INITGROUPS"
- CXXFLAGS="$CXXFLAGS -DHAVE_INT_8_16_32 -DUNDEF_HAVE_INITGROUPS"
+ CFLAGS="$CFLAGS -DUNDEF_HAVE_INITGROUPS"
+ CXXFLAGS="$CXXFLAGS -DUNDEF_HAVE_INITGROUPS"
;;
esac