summaryrefslogtreecommitdiff
path: root/config/ac-macros/misc.m4
diff options
context:
space:
mode:
authorunknown <kent@mysql.com/kent-amd64.(none)>2007-07-23 23:54:55 +0200
committerunknown <kent@mysql.com/kent-amd64.(none)>2007-07-23 23:54:55 +0200
commit54cebc4764260bf06c334e9644110fd5e369470f (patch)
tree62f5f058036f8b56ecfde5e8b3e2cccd48b8fd1e /config/ac-macros/misc.m4
parentce203858e907a2f69de0e96fd5b40dc3935985e8 (diff)
downloadmariadb-git-54cebc4764260bf06c334e9644110fd5e369470f.tar.gz
Many files:
Put back old code to check stack direction at configure time config/ac-macros/misc.m4: Put back old code to check stack direction at configure time configure.in: Put back old code to check stack direction at configure time include/config-netware.h: Put back old code to check stack direction at configure time include/config-win.h: Put back old code to check stack direction at configure time include/my_global.h: Put back old code to check stack direction at configure time sql/sql_parse.cc: Put back old code to check stack direction at configure time
Diffstat (limited to 'config/ac-macros/misc.m4')
-rw-r--r--config/ac-macros/misc.m423
1 files changed, 23 insertions, 0 deletions
diff --git a/config/ac-macros/misc.m4 b/config/ac-macros/misc.m4
index 0619a52fbbf..9f84e06fa46 100644
--- a/config/ac-macros/misc.m4
+++ b/config/ac-macros/misc.m4
@@ -450,6 +450,29 @@ AC_DEFINE([HAVE_BOOL], [1], [bool is not defined by all C++ compilators])
fi
])dnl
+AC_DEFUN([MYSQL_STACK_DIRECTION],
+ [AC_CACHE_CHECK(stack direction for C alloca, ac_cv_c_stack_direction,
+ [AC_TRY_RUN([#include <stdlib.h>
+ int find_stack_direction ()
+ {
+ static char *addr = 0;
+ auto char dummy;
+ if (addr == 0)
+ {
+ addr = &dummy;
+ return find_stack_direction ();
+ }
+ else
+ return (&dummy > addr) ? 1 : -1;
+ }
+ int main ()
+ {
+ exit (find_stack_direction() < 0);
+ }], ac_cv_c_stack_direction=1, ac_cv_c_stack_direction=-1,
+ ac_cv_c_stack_direction=)])
+ AC_DEFINE_UNQUOTED(STACK_DIRECTION, $ac_cv_c_stack_direction)
+])dnl
+
AC_DEFUN([MYSQL_CHECK_LONGLONG_TO_FLOAT],
[
AC_MSG_CHECKING(if conversion of longlong to float works)