Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit e295c55

Browse files
committed
Check for gmake, then make, when doing thread test.
1 parent f5dd5bf commit e295c55

File tree

2 files changed

+48
-7
lines changed

2 files changed

+48
-7
lines changed

configure

Lines changed: 43 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19118,19 +19118,59 @@ fi
1911819118
#
1911919119
if test "$enable_thread_safety" = yes; then
1912019120
if test cross_compiling != yes; then
19121+
for ac_prog in gmake make
19122+
do
19123+
# Extract the first word of "$ac_prog", so it can be a program name with args.
19124+
set dummy $ac_prog; ac_word=$2
19125+
echo "$as_me:$LINENO: checking for $ac_word" >&5
19126+
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
19127+
if test "${ac_cv_prog_MAKE+set}" = set; then
19128+
echo $ECHO_N "(cached) $ECHO_C" >&6
19129+
else
19130+
if test -n "$MAKE"; then
19131+
ac_cv_prog_MAKE="$MAKE" # Let the user override the test.
19132+
else
19133+
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19134+
for as_dir in $PATH
19135+
do
19136+
IFS=$as_save_IFS
19137+
test -z "$as_dir" && as_dir=.
19138+
for ac_exec_ext in '' $ac_executable_extensions; do
19139+
if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19140+
ac_cv_prog_MAKE="$ac_prog"
19141+
echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
19142+
break 2
19143+
fi
19144+
done
19145+
done
19146+
19147+
fi
19148+
fi
19149+
MAKE=$ac_cv_prog_MAKE
19150+
if test -n "$MAKE"; then
19151+
echo "$as_me:$LINENO: result: $MAKE" >&5
19152+
echo "${ECHO_T}$MAKE" >&6
19153+
else
19154+
echo "$as_me:$LINENO: result: no" >&5
19155+
echo "${ECHO_T}no" >&6
19156+
fi
19157+
19158+
test -n "$MAKE" && break
19159+
done
19160+
1912119161
echo "$as_me:$LINENO: checking thread safety of required library functions." >&5
1912219162
echo $ECHO_N "checking thread safety of required library functions.... $ECHO_C" >&6
1912319163
#
1912419164
# Clean, compile, run, and clean thread test directory.
1912519165
# If test fails for any reason, remove Makefile.global so the user can't
1912619166
# compile (to simulate a configure failure).
1912719167
#
19128-
gmake -C $srcdir/src/tools/thread clean >&5 ||
19168+
$MAKE -C $srcdir/src/tools/thread clean >&5 ||
1912919169
( rm -f src/Makefile.global
1913019170
{ { echo "$as_me:$LINENO: error: Can not clean thread test directory." >&5
1913119171
echo "$as_me: error: Can not clean thread test directory." >&2;}
1913219172
{ (exit 1); exit 1; }; })
19133-
gmake -C $srcdir/src/tools/thread >&5 ||
19173+
$MAKE -C $srcdir/src/tools/thread >&5 ||
1913419174
( rm -f src/Makefile.global
1913519175
{ { echo "$as_me:$LINENO: error: Can not build thread test proram." >&5
1913619176
echo "$as_me: error: Can not build thread test proram." >&2;}
@@ -19140,7 +19180,7 @@ $srcdir/src/tools/thread/thread_test >&5 ||
1914019180
{ { echo "$as_me:$LINENO: error: Thread test program failed." >&5
1914119181
echo "$as_me: error: Thread test program failed." >&2;}
1914219182
{ (exit 1); exit 1; }; })
19143-
gmake -C $srcdir/src/tools/thread clean >&5 ||
19183+
$MAKE -C $srcdir/src/tools/thread clean >&5 ||
1914419184
( rm -f src/Makefile.global
1914519185
{ { echo "$as_me:$LINENO: error: Can not clean thread test directory." >&5
1914619186
echo "$as_me: error: Can not clean thread test directory." >&2;}

configure.in

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
dnl Process this file with autoconf to produce a configure script.
2-
dnl $PostgreSQL: pgsql/configure.in,v 1.325 2004/04/23 23:58:07 momjian Exp $
2+
dnl $PostgreSQL: pgsql/configure.in,v 1.326 2004/04/24 03:09:35 momjian Exp $
33
dnl
44
dnl Developers, please strive to achieve this order:
55
dnl
@@ -1220,22 +1220,23 @@ AC_OUTPUT
12201220
#
12211221
if test "$enable_thread_safety" = yes; then
12221222
if test cross_compiling != yes; then
1223+
AC_CHECK_PROGS(MAKE, gmake make)
12231224
AC_MSG_CHECKING([thread safety of required library functions.])
12241225
#
12251226
# Clean, compile, run, and clean thread test directory.
12261227
# If test fails for any reason, remove Makefile.global so the user can't
12271228
# compile (to simulate a configure failure).
12281229
#
1229-
gmake -C $srcdir/src/tools/thread clean >&5 ||
1230+
$MAKE -C $srcdir/src/tools/thread clean >&5 ||
12301231
( rm -f src/Makefile.global
12311232
AC_MSG_ERROR([Can not clean thread test directory.]))
1232-
gmake -C $srcdir/src/tools/thread >&5 ||
1233+
$MAKE -C $srcdir/src/tools/thread >&5 ||
12331234
( rm -f src/Makefile.global
12341235
AC_MSG_ERROR([Can not build thread test proram.]))
12351236
$srcdir/src/tools/thread/thread_test >&5 ||
12361237
( rm -f src/Makefile.global
12371238
AC_MSG_ERROR([Thread test program failed.]))
1238-
gmake -C $srcdir/src/tools/thread clean >&5 ||
1239+
$MAKE -C $srcdir/src/tools/thread clean >&5 ||
12391240
( rm -f src/Makefile.global
12401241
AC_MSG_ERROR([Can not clean thread test directory.]))
12411242
echo "yes"

0 commit comments

Comments
 (0)