pike.git
/
src
/
configure.in
version
»
Context lines:
10
20
40
80
file
none
3
pike.git/src/configure.in:4682:
fi ######################################################################## AC_MSG_CHECKING(stack direction) AC_CACHE_VAL(pike_cv_hardware_stack_direction, [ AC_TRY_RUN([ #include <stdio.h>
+
static int (* volatile find_stack_direction_funptr)(void *foo, int cnt);
static int find_stack_direction(void *foo, int cnt) {
-
if (cnt) return 1*find_stack_direction(foo, cnt>>1);
+
if (cnt) return 1*find_stack_direction
_funptr
(foo, cnt>>1);
if (((void *)&foo) > foo) { return 1; } else { return -1; } }
-
int main() { void *bar; exit( find_stack_direction(&bar, 0x10) > 0);
}
+
int main() {
+
find_stack_direction_funptr = &find_stack_direction;
+
void *bar; exit( find_stack_direction
_funptr
(&bar, 0x10) > 0);
+
}
], [ pike_cv_hardware_stack_direction=down ], [ pike_cv_hardware_stack_direction=up ], [ AC_MSG_WARN([Defaulting to down.]) pike_cv_hardware_stack_direction=down ]) ]) AC_MSG_RESULT($pike_cv_hardware_stack_direction)