summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@polymtl.ca>2016-11-17 12:00:10 -0500
committerSimon Marchi <simon.marchi@ericsson.com>2016-11-17 12:00:10 -0500
commit3b165252e882c05c8217f888194877224295592d (patch)
tree33908b57c464bc235309cb3982384d5e4083db6c
parentf2ff9acd32b4667ee16a03ca8d10fd8b99e22f46 (diff)
Remove code that checks for GNU/non-GNU make
Since GNU make is now required to build GDB, we can remove everything that checks whether the current make implemention is the GNU one or not. I simply removed the @GMAKE_TRUE@ prefixes and removed the whole lines that were prefixed with @GMAKE_FALSE@. I removed the code in the configure scripts that set those variables. I also removed the following bits from the configure scripts: AC_CHECK_PROGS(MAKE, make): GNU make already defines a MAKE variable internally to be used when invoking Makefiles recursively. I don't see this variable being used anywhere else (in scripts for example), so I think it's safe for removal. AC_PROG_MAKE_SET: This macro defines a SET_MAKE output variable, which is meant to be used in Makefiles to define the MAKE variable when using an implementation of make that doesn't already define it. Since we are now requiring GNU make, we don't need it anymore. Plus, I don't see SET_MAKE being used anywhere, so I don't think it was actually doing anything... gdb/ChangeLog: * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines prefixed with @GMAKE_FALSE@. Update comment related to non-GNU make. * configure.ac: Remove checks for the make program. * configure: Re-generate. gdb/gdbserver/ChangeLog: * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines prefixed with @GMAKE_FALSE@. Update comment related to non-GNU make. * configure.ac: Remove checks for the make program. * configure: Re-generate. gdb/testsuite/ChangeLog: * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines prefixed with @GMAKE_FALSE@. Update comment related to non-GNU make. * configure.ac: Remove checks for the make program. * configure: Re-generate.
-rw-r--r--gdb/ChangeLog8
-rw-r--r--gdb/Makefile.in34
-rwxr-xr-xgdb/configure97
-rw-r--r--gdb/configure.ac11
-rw-r--r--gdb/gdbserver/ChangeLog8
-rw-r--r--gdb/gdbserver/Makefile.in34
-rwxr-xr-xgdb/gdbserver/configure97
-rw-r--r--gdb/gdbserver/configure.ac11
-rw-r--r--gdb/testsuite/ChangeLog8
-rw-r--r--gdb/testsuite/Makefile.in88
-rwxr-xr-xgdb/testsuite/configure99
-rw-r--r--gdb/testsuite/configure.ac11
12 files changed, 98 insertions, 408 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index c0c7d7fec6..9547d5017b 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,13 @@
2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
+ * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
+ prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
+ make.
+ * configure.ac: Remove checks for the make program.
+ * configure: Re-generate.
+
+2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
+
* NEWS: Mention requirement of GNU make.
2016-11-17 Pedro Alves <palves@redhat.com>
diff --git a/gdb/Makefile.in b/gdb/Makefile.in
index 3876cd92ac..f53b1216ce 100644
--- a/gdb/Makefile.in
+++ b/gdb/Makefile.in
@@ -2734,26 +2734,24 @@ py-varobj.o: $(srcdir)/python/py-varobj.c
$(POSTCOMPILE)
#
-# Dependency tracking. Most of this is conditional on GNU Make being
-# found by configure; if GNU Make is not found, we fall back to a
-# simpler scheme.
+# Dependency tracking.
#
-@GMAKE_TRUE@ifeq ($(DEPMODE),depmode=gcc3)
+ifeq ($(DEPMODE),depmode=gcc3)
# Note that we put the dependencies into a .Tpo file, then move them
# into place if the compile succeeds. We need this because gcc does
# not atomically write the dependency output file.
-@GMAKE_TRUE@override COMPILE.post = -c -o $@ -MT $@ -MMD -MP \
-@GMAKE_TRUE@ -MF $(DEPDIR)/$(basename $(@F)).Tpo
-@GMAKE_TRUE@override POSTCOMPILE = @mv $(DEPDIR)/$(basename $(@F)).Tpo \
-@GMAKE_TRUE@ $(DEPDIR)/$(basename $(@F)).Po
-@GMAKE_TRUE@else
-@GMAKE_TRUE@override COMPILE.pre = source='$<' object='$@' libtool=no \
-@GMAKE_TRUE@ DEPDIR=$(DEPDIR) $(DEPMODE) $(depcomp) $(CC)
+override COMPILE.post = -c -o $@ -MT $@ -MMD -MP \
+ -MF $(DEPDIR)/$(basename $(@F)).Tpo
+override POSTCOMPILE = @mv $(DEPDIR)/$(basename $(@F)).Tpo \
+ $(DEPDIR)/$(basename $(@F)).Po
+else
+override COMPILE.pre = source='$<' object='$@' libtool=no \
+ DEPDIR=$(DEPDIR) $(DEPMODE) $(depcomp) $(CC)
# depcomp handles atomicity for us, so we don't need a postcompile
# step.
-@GMAKE_TRUE@override POSTCOMPILE =
-@GMAKE_TRUE@endif
+override POSTCOMPILE =
+endif
# A list of all the objects we might care about in this build, for
# dependency tracking.
@@ -2763,13 +2761,13 @@ all_object_files = gdb.o $(LIBGDB_OBS) gdbtk-main.o \
# Ensure that generated files are created early. Use order-only
# dependencies if available. They require GNU make 3.80 or newer,
# and the .VARIABLES variable was introduced at the same time.
-@GMAKE_TRUE@ifdef .VARIABLES
-@GMAKE_TRUE@$(all_object_files): | $(generated_files)
-@GMAKE_TRUE@else
+ifdef .VARIABLES
+$(all_object_files): | $(generated_files)
+else
$(all_object_files) : $(generated_files)
-@GMAKE_TRUE@endif
+endif
# Dependencies.
-@GMAKE_TRUE@-include $(patsubst %.o, $(DEPDIR)/%.Po, $(all_object_files))
+-include $(patsubst %.o, $(DEPDIR)/%.Po, $(all_object_files))
### end of the gdb Makefile.in.
diff --git a/gdb/configure b/gdb/configure
index cf80bef7ed..2abfbff6fd 100755
--- a/gdb/configure
+++ b/gdb/configure
@@ -725,10 +725,6 @@ INCINTL
LIBINTL_DEP
LIBINTL
USE_NLS
-SET_MAKE
-GMAKE_FALSE
-GMAKE_TRUE
-MAKE
CCDEPMODE
DEPDIR
am__leading_dot
@@ -6043,95 +6039,6 @@ else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
fi
-# Check for the 'make' the user wants to use.
-for ac_prog in make
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_MAKE+set}" = set; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$MAKE"; then
- ac_cv_prog_MAKE="$MAKE" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_prog_MAKE="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-MAKE=$ac_cv_prog_MAKE
-if test -n "$MAKE"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5
-$as_echo "$MAKE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$MAKE" && break
-done
-
-MAKE_IS_GNU=
-case "`$MAKE --version 2>&1 | sed 1q`" in
- *GNU*)
- MAKE_IS_GNU=yes
- ;;
-esac
- if test "$MAKE_IS_GNU" = yes; then
- GMAKE_TRUE=
- GMAKE_FALSE='#'
-else
- GMAKE_TRUE='#'
- GMAKE_FALSE=
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
-set x ${MAKE-make}
-ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
- $as_echo_n "(cached) " >&6
-else
- cat >conftest.make <<\_ACEOF
-SHELL = /bin/sh
-all:
- @echo '@@@%%%=$(MAKE)=@@@%%%'
-_ACEOF
-# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
-case `${MAKE-make} -f conftest.make 2>/dev/null` in
- *@@@%%%=?*=@@@%%%*)
- eval ac_cv_prog_make_${ac_make}_set=yes;;
- *)
- eval ac_cv_prog_make_${ac_make}_set=no;;
-esac
-rm -f conftest.make
-fi
-if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- SET_MAKE=
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-
gnulib_extra_configure_args=
# If large-file support is disabled, make sure gnulib does the same.
if test "$enable_largefile" = no; then
@@ -17627,10 +17534,6 @@ if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
as_fn_error "conditional \"MAINTAINER_MODE\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
fi
-if test -z "${GMAKE_TRUE}" && test -z "${GMAKE_FALSE}"; then
- as_fn_error "conditional \"GMAKE\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
if test -z "${HAVE_PYTHON_TRUE}" && test -z "${HAVE_PYTHON_FALSE}"; then
as_fn_error "conditional \"HAVE_PYTHON\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
diff --git a/gdb/configure.ac b/gdb/configure.ac
index 592b1beb92..585f1477c2 100644
--- a/gdb/configure.ac
+++ b/gdb/configure.ac
@@ -46,17 +46,6 @@ AX_CXX_COMPILE_STDCXX(11, , mandatory)
ZW_CREATE_DEPDIR
ZW_PROG_COMPILER_DEPENDENCIES([CC])
-# Check for the 'make' the user wants to use.
-AC_CHECK_PROGS(MAKE, make)
-MAKE_IS_GNU=
-case "`$MAKE --version 2>&1 | sed 1q`" in
- *GNU*)
- MAKE_IS_GNU=yes
- ;;
-esac
-AM_CONDITIONAL(GMAKE, test "$MAKE_IS_GNU" = yes)
-AC_PROG_MAKE_SET
-
gnulib_extra_configure_args=
# If large-file support is disabled, make sure gnulib does the same.
if test "$enable_largefile" = no; then
diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog
index 2ce767927f..4b463cf3b2 100644
--- a/gdb/gdbserver/ChangeLog
+++ b/gdb/gdbserver/ChangeLog
@@ -1,3 +1,11 @@
+2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
+
+ * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
+ prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
+ make.
+ * configure.ac: Remove checks for the make program.
+ * configure: Re-generate.
+
2016-10-28 Pedro Alves <palves@redhat.com>
* Makefile.in (CXX_DIALECT): Get from configure.
diff --git a/gdb/gdbserver/Makefile.in b/gdb/gdbserver/Makefile.in
index 5ba559cfa5..a1f46758b2 100644
--- a/gdb/gdbserver/Makefile.in
+++ b/gdb/gdbserver/Makefile.in
@@ -974,26 +974,24 @@ reg-tilegx32.c : $(srcdir)/../regformats/reg-tilegx32.dat $(regdat_sh)
$(SHELL) $(regdat_sh) $(srcdir)/../regformats/reg-tilegx32.dat reg-tilegx32.c
#
-# Dependency tracking. Most of this is conditional on GNU Make being
-# found by configure; if GNU Make is not found, we fall back to a
-# simpler scheme.
+# Dependency tracking.
#
-@GMAKE_TRUE@ifeq ($(DEPMODE),depmode=gcc3)
+ifeq ($(DEPMODE),depmode=gcc3)
# Note that we put the dependencies into a .Tpo file, then move them
# into place if the compile succeeds. We need this because gcc does
# not atomically write the dependency output file.
-@GMAKE_TRUE@override COMPILE.post = -c -o $@ -MT $@ -MMD -MP \
-@GMAKE_TRUE@ -MF $(DEPDIR)/$(basename $(@F)).Tpo
-@GMAKE_TRUE@override POSTCOMPILE = @mv $(DEPDIR)/$(basename $(@F)).Tpo \
-@GMAKE_TRUE@ $(DEPDIR)/$(basename $(@F)).Po
-@GMAKE_TRUE@else
-@GMAKE_TRUE@override COMPILE.pre = source='$<' object='$@' libtool=no \
-@GMAKE_TRUE@ DEPDIR=$(DEPDIR) $(DEPMODE) $(depcomp) $(CC)
+override COMPILE.post = -c -o $@ -MT $@ -MMD -MP \
+ -MF $(DEPDIR)/$(basename $(@F)).Tpo
+override POSTCOMPILE = @mv $(DEPDIR)/$(basename $(@F)).Tpo \
+ $(DEPDIR)/$(basename $(@F)).Po
+else
+override COMPILE.pre = source='$<' object='$@' libtool=no \
+ DEPDIR=$(DEPDIR) $(DEPMODE) $(depcomp) $(CC)
# depcomp handles atomicity for us, so we don't need a postcompile
# step.
-@GMAKE_TRUE@override POSTCOMPILE =
-@GMAKE_TRUE@endif
+override POSTCOMPILE =
+endif
# A list of all the objects we might care about in this build, for
# dependency tracking.
@@ -1002,13 +1000,13 @@ all_object_files = $(OBS) $(GDBREPLAY_OBS) $(IPA_OBJS)
# Ensure that generated files are created early. Use order-only
# dependencies if available. They require GNU make 3.80 or newer,
# and the .VARIABLES variable was introduced at the same time.
-@GMAKE_TRUE@ifdef .VARIABLES
-@GMAKE_TRUE@$(all_object_files): | $(generated_files)
-@GMAKE_TRUE@else
+ifdef .VARIABLES
+$(all_object_files): | $(generated_files)
+else
$(all_object_files) : $(generated_files)
-@GMAKE_TRUE@endif
+endif
# Dependencies.
-@GMAKE_TRUE@-include $(patsubst %.o, $(DEPDIR)/%.Po, $(all_object_files))
+-include $(patsubst %.o, $(DEPDIR)/%.Po, $(all_object_files))
# This is the end of "Makefile.in".
diff --git a/gdb/gdbserver/configure b/gdb/gdbserver/configure
index bbce742eeb..53c26f39f4 100755
--- a/gdb/gdbserver/configure
+++ b/gdb/gdbserver/configure
@@ -606,10 +606,6 @@ WARN_CFLAGS
ustinc
ustlibs
ALLOCA
-SET_MAKE
-GMAKE_FALSE
-GMAKE_TRUE
-MAKE
CCDEPMODE
DEPDIR
am__leading_dot
@@ -5949,95 +5945,6 @@ else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
fi
-# Check for the 'make' the user wants to use.
-for ac_prog in make
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_MAKE+set}" = set; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$MAKE"; then
- ac_cv_prog_MAKE="$MAKE" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_prog_MAKE="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-MAKE=$ac_cv_prog_MAKE
-if test -n "$MAKE"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5
-$as_echo "$MAKE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$MAKE" && break
-done
-
-MAKE_IS_GNU=
-case "`$MAKE --version 2>&1 | sed 1q`" in
- *GNU*)
- MAKE_IS_GNU=yes
- ;;
-esac
- if test "$MAKE_IS_GNU" = yes; then
- GMAKE_TRUE=
- GMAKE_FALSE='#'
-else
- GMAKE_TRUE='#'
- GMAKE_FALSE=
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
-set x ${MAKE-make}
-ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
- $as_echo_n "(cached) " >&6
-else
- cat >conftest.make <<\_ACEOF
-SHELL = /bin/sh
-all:
- @echo '@@@%%%=$(MAKE)=@@@%%%'
-_ACEOF
-# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
-case `${MAKE-make} -f conftest.make 2>/dev/null` in
- *@@@%%%=?*=@@@%%%*)
- eval ac_cv_prog_make_${ac_make}_set=yes;;
- *)
- eval ac_cv_prog_make_${ac_make}_set=no;;
-esac
-rm -f conftest.make
-fi
-if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- SET_MAKE=
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-
gnulib_extra_configure_args=
# If large-file support is disabled, make sure gnulib does the same.
if test "$enable_largefile" = no; then
@@ -8615,10 +8522,6 @@ if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
as_fn_error "conditional \"MAINTAINER_MODE\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
fi
-if test -z "${GMAKE_TRUE}" && test -z "${GMAKE_FALSE}"; then
- as_fn_error "conditional \"GMAKE\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
: ${CONFIG_STATUS=./config.status}
ac_write_fail=0
diff --git a/gdb/gdbserver/configure.ac b/gdb/gdbserver/configure.ac
index 11d8c79cdc..6858e5193b 100644
--- a/gdb/gdbserver/configure.ac
+++ b/gdb/gdbserver/configure.ac
@@ -63,17 +63,6 @@ ACX_NONCANONICAL_HOST
ZW_CREATE_DEPDIR
ZW_PROG_COMPILER_DEPENDENCIES([CC])
-# Check for the 'make' the user wants to use.
-AC_CHECK_PROGS(MAKE, make)
-MAKE_IS_GNU=
-case "`$MAKE --version 2>&1 | sed 1q`" in
- *GNU*)
- MAKE_IS_GNU=yes
- ;;
-esac
-AM_CONDITIONAL(GMAKE, test "$MAKE_IS_GNU" = yes)
-AC_PROG_MAKE_SET
-
gnulib_extra_configure_args=
# If large-file support is disabled, make sure gnulib does the same.
if test "$enable_largefile" = no; then
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index 82126c03f4..8d779811a3 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,3 +1,11 @@
+2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
+
+ * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
+ prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
+ make.
+ * configure.ac: Remove checks for the make program.
+ * configure: Re-generate.
+
2016-11-16 Kevin Buettner <kevinb@redhat.com>
* gdb.python/py-recurse-unwind.c (main): Add loop.
diff --git a/gdb/testsuite/Makefile.in b/gdb/testsuite/Makefile.in
index 7853275617..29897abea1 100644
--- a/gdb/testsuite/Makefile.in
+++ b/gdb/testsuite/Makefile.in
@@ -140,15 +140,13 @@ installcheck:
# See whether -j was given to make. Either it was given with no
# arguments, and appears as "j" in the first word, or it was given an
# argument and appears as "-j" in a separate word.
-@GMAKE_TRUE@saw_dash_j = $(or $(findstring j,$(firstword $(MAKEFLAGS))),$(filter -j,$(MAKEFLAGS)))
+saw_dash_j = $(or $(findstring j,$(firstword $(MAKEFLAGS))),$(filter -j,$(MAKEFLAGS)))
-# For GNU make, try to run the tests in parallel if any -j option is
-# given. If RUNTESTFLAGS is not empty, then by default the tests will
-# be serialized. This can be overridden by setting FORCE_PARALLEL to
-# any non-empty value. For a non-GNU make, do not parallelize.
-@GMAKE_TRUE@CHECK_TARGET_TMP = $(if $(FORCE_PARALLEL),check-parallel,$(if $(RUNTESTFLAGS),check-single,$(if $(saw_dash_j),check-parallel,check-single)))
-@GMAKE_TRUE@CHECK_TARGET = $(if $(RACY_ITER),$(addsuffix -racy,$(CHECK_TARGET_TMP)),$(CHECK_TARGET_TMP))
-@GMAKE_FALSE@CHECK_TARGET = check-single
+# Try to run the tests in parallel if any -j option is given. If RUNTESTFLAGS
+# is not empty, then by default the tests will be serialized. This can be
+# overridden by setting FORCE_PARALLEL to any non-empty value.
+CHECK_TARGET_TMP = $(if $(FORCE_PARALLEL),check-parallel,$(if $(RUNTESTFLAGS),check-single,$(if $(saw_dash_j),check-parallel,check-single)))
+CHECK_TARGET = $(if $(RACY_ITER),$(addsuffix -racy,$(CHECK_TARGET_TMP)),$(CHECK_TARGET_TMP))
# Note that we must resort to a recursive make invocation here,
# because GNU make 3.82 has a bug preventing MAKEFLAGS from being used
@@ -179,20 +177,18 @@ DO_RUNTEST = \
# of tests. For consistency we support it for check-single as well.
# To specify all tests in a subdirectory, use TESTS=gdb.subdir/*.exp.
# E.g., make check TESTS="gdb.server/*.exp gdb.threads/*.exp".
-@GMAKE_TRUE@TESTS :=
-@GMAKE_FALSE@TESTS =
+TESTS :=
-@GMAKE_TRUE@ifeq ($(strip $(TESTS)),)
-@GMAKE_TRUE@expanded_tests_or_none :=
-@GMAKE_TRUE@else
-@GMAKE_TRUE@expanded_tests := $(patsubst $(srcdir)/%,%,$(wildcard $(addprefix $(srcdir)/,$(TESTS))))
-@GMAKE_TRUE@expanded_tests_or_none := $(or $(expanded_tests),no-matching-tests-found)
-@GMAKE_TRUE@endif
-@GMAKE_FALSE@expanded_tests_or_none = $(TESTS)
+ifeq ($(strip $(TESTS)),)
+expanded_tests_or_none :=
+else
+expanded_tests := $(patsubst $(srcdir)/%,%,$(wildcard $(addprefix $(srcdir)/,$(TESTS))))
+expanded_tests_or_none := $(or $(expanded_tests),no-matching-tests-found)
+endif
# Shorthand for running all the tests in a single directory.
-@GMAKE_TRUE@check-gdb.%:
-@GMAKE_TRUE@ $(MAKE) check TESTS="gdb.$*/*.exp"
+check-gdb.%:
+ $(MAKE) check TESTS="gdb.$*/*.exp"
check-single:
$(DO_RUNTEST) $(RUNTESTFLAGS) $(expanded_tests_or_none)
@@ -261,31 +257,31 @@ check-parallel-racy:
# them to the front of the list to try to lessen the overall time
# taken by the test suite -- if one of these tests happens to be run
# late, it will cause the overall time to increase.
-@GMAKE_TRUE@ifeq ($(strip $(TESTS)),)
+ifeq ($(strip $(TESTS)),)
slow_tests = gdb.base/break-interp.exp gdb.base/interp.exp \
gdb.base/multi-forks.exp
-@GMAKE_TRUE@all_tests := $(shell cd $(srcdir) && find gdb.* -name '*.exp' -print)
-@GMAKE_TRUE@reordered_tests := $(slow_tests) $(filter-out $(slow_tests),$(all_tests))
-@GMAKE_TRUE@TEST_TARGETS := $(addprefix $(if $(RACY_ITER),check-racy,check)/,$(reordered_tests))
-@GMAKE_TRUE@else
-@GMAKE_TRUE@TEST_TARGETS := $(addprefix $(if $(RACY_ITER),check-racy,check)/,$(expanded_tests_or_none))
-@GMAKE_TRUE@endif
+all_tests := $(shell cd $(srcdir) && find gdb.* -name '*.exp' -print)
+reordered_tests := $(slow_tests) $(filter-out $(slow_tests),$(all_tests))
+TEST_TARGETS := $(addprefix $(if $(RACY_ITER),check-racy,check)/,$(reordered_tests))
+else
+TEST_TARGETS := $(addprefix $(if $(RACY_ITER),check-racy,check)/,$(expanded_tests_or_none))
+endif
do-check-parallel: $(TEST_TARGETS)
@:
-@GMAKE_TRUE@check/%.exp:
-@GMAKE_TRUE@ -mkdir -p outputs/$*
-@GMAKE_TRUE@ @$(DO_RUNTEST) GDB_PARALLEL=yes --outdir=outputs/$* $*.exp $(RUNTESTFLAGS)
+check/%.exp:
+ -mkdir -p outputs/$*
+ @$(DO_RUNTEST) GDB_PARALLEL=yes --outdir=outputs/$* $*.exp $(RUNTESTFLAGS)
do-check-parallel-racy: $(TEST_TARGETS)
@:
-@GMAKE_TRUE@check-racy/%.exp:
-@GMAKE_TRUE@ -mkdir -p racy_outputs/$(RACY_OUTPUT_N)/$*
-@GMAKE_TRUE@ $(DO_RUNTEST) GDB_PARALLEL=yes \
-@GMAKE_TRUE@ --outdir=racy_outputs/$(RACY_OUTPUT_N)/$* $*.exp \
-@GMAKE_TRUE@ $(RUNTESTFLAGS)
+check-racy/%.exp:
+ -mkdir -p racy_outputs/$(RACY_OUTPUT_N)/$*
+ $(DO_RUNTEST) GDB_PARALLEL=yes \
+ --outdir=racy_outputs/$(RACY_OUTPUT_N)/$* $*.exp \
+ $(RUNTESTFLAGS)
check/no-matching-tests-found:
@echo ""
@@ -293,9 +289,9 @@ check/no-matching-tests-found:
@echo ""
# Utility rule invoked by step 2 of the build-perf rule.
-@GMAKE_TRUE@workers/%.worker:
-@GMAKE_TRUE@ mkdir -p gdb.perf/outputs/$*
-@GMAKE_TRUE@ $(DO_RUNTEST) --outdir=gdb.perf/outputs/$* lib/build-piece.exp WORKER=$* GDB_PARALLEL=gdb.perf $(RUNTESTFLAGS) GDB_PERFTEST_MODE=compile GDB_PERFTEST_SUBMODE=build-pieces
+workers/%.worker:
+ mkdir -p gdb.perf/outputs/$*
+ $(DO_RUNTEST) --outdir=gdb.perf/outputs/$* lib/build-piece.exp WORKER=$* GDB_PARALLEL=gdb.perf $(RUNTESTFLAGS) GDB_PERFTEST_MODE=compile GDB_PERFTEST_SUBMODE=build-pieces
# Utility rule to build tests that support it in parallel.
# The build is broken into 3 steps distinguished by GDB_PERFTEST_SUBMODE:
@@ -311,15 +307,15 @@ check/no-matching-tests-found:
# The point of step 1 is to construct the set of worker tasks for step 2.
# All of the information needed by build-piece.exp is contained in the name
# of the generated .worker file.
-@GMAKE_TRUE@build-perf: $(abs_builddir)/site.exp
-@GMAKE_TRUE@ rm -rf gdb.perf/workers
-@GMAKE_TRUE@ mkdir -p gdb.perf/workers
-@GMAKE_TRUE@ @: Step 1: Generate the build .worker files.
-@GMAKE_TRUE@ $(DO_RUNTEST) --directory=gdb.perf --outdir gdb.perf/workers GDB_PARALLEL=gdb.perf $(RUNTESTFLAGS) GDB_PERFTEST_MODE=compile GDB_PERFTEST_SUBMODE=gen-workers
-@GMAKE_TRUE@ @: Step 2: Compile the pieces. Here is the build parallelism.
-@GMAKE_TRUE@ $(MAKE) $$(cd gdb.perf && echo workers/*/*.worker)
-@GMAKE_TRUE@ @: Step 3: Do the final link.
-@GMAKE_TRUE@ $(DO_RUNTEST) --directory=gdb.perf --outdir gdb.perf GDB_PARALLEL=gdb.perf $(RUNTESTFLAGS) GDB_PERFTEST_MODE=compile GDB_PERFTEST_SUBMODE=final
+build-perf: $(abs_builddir)/site.exp
+ rm -rf gdb.perf/workers
+ mkdir -p gdb.perf/workers
+ @: Step 1: Generate the build .worker files.
+ $(DO_RUNTEST) --directory=gdb.perf --outdir gdb.perf/workers GDB_PARALLEL=gdb.perf $(RUNTESTFLAGS) GDB_PERFTEST_MODE=compile GDB_PERFTEST_SUBMODE=gen-workers
+ @: Step 2: Compile the pieces. Here is the build parallelism.
+ $(MAKE) $$(cd gdb.perf && echo workers/*/*.worker)
+ @: Step 3: Do the final link.
+ $(DO_RUNTEST) --directory=gdb.perf --outdir gdb.perf GDB_PARALLEL=gdb.perf $(RUNTESTFLAGS) GDB_PERFTEST_MODE=compile GDB_PERFTEST_SUBMODE=final
# The default is to both compile and run the tests.
GDB_PERFTEST_MODE = both
diff --git a/gdb/testsuite/configure b/gdb/testsuite/configure
index 976dbe8bc8..5ea3cb1869 100755
--- a/gdb/testsuite/configure
+++ b/gdb/testsuite/configure
@@ -608,10 +608,6 @@ CFLAGS
CC
RPATH_ENVVAR
subdirs
-SET_MAKE
-GMAKE_FALSE
-GMAKE_TRUE
-MAKE
target_noncanonical
target_os
target_vendor
@@ -2130,97 +2126,6 @@ esac
-# Check for the 'make' the user wants to use.
-for ac_prog in make
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_prog_MAKE+set}" = set; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$MAKE"; then
- ac_cv_prog_MAKE="$MAKE" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_prog_MAKE="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-MAKE=$ac_cv_prog_MAKE
-if test -n "$MAKE"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5
-$as_echo "$MAKE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$MAKE" && break
-done
-
-MAKE_IS_GNU=
-case "`$MAKE --version 2>&1 | sed 1q`" in
- *GNU*)
- MAKE_IS_GNU=yes
- ;;
-esac
-
-
-if test "$MAKE_IS_GNU" = yes; then
- GMAKE_TRUE=
- GMAKE_FALSE='#'
-else
- GMAKE_TRUE='#'
- GMAKE_FALSE=
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
-set x ${MAKE-make}
-ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
- $as_echo_n "(cached) " >&6
-else
- cat >conftest.make <<\_ACEOF
-SHELL = /bin/sh
-all:
- @echo '@@@%%%=$(MAKE)=@@@%%%'
-_ACEOF
-# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
-case `${MAKE-make} -f conftest.make 2>/dev/null` in
- *@@@%%%=?*=@@@%%%*)
- eval ac_cv_prog_make_${ac_make}_set=yes;;
- *)
- eval ac_cv_prog_make_${ac_make}_set=no;;
-esac
-rm -f conftest.make
-fi
-if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- SET_MAKE=
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-
# Enable gdbtk.
# Check whether --enable-gdbtk was given.
if test "${enable_gdbtk+set}" = set; then :
@@ -3647,10 +3552,6 @@ LIBOBJS=$ac_libobjs
LTLIBOBJS=$ac_ltlibobjs
-if test -z "${GMAKE_TRUE}" && test -z "${GMAKE_FALSE}"; then
- as_fn_error "conditional \"GMAKE\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
: ${CONFIG_STATUS=./config.status}
ac_write_fail=0
diff --git a/gdb/testsuite/configure.ac b/gdb/testsuite/configure.ac
index 91e5d22c91..2915a18757 100644
--- a/gdb/testsuite/configure.ac
+++ b/gdb/testsuite/configure.ac
@@ -25,17 +25,6 @@ AC_CANONICAL_TARGET
ACX_NONCANONICAL_TARGET
-# Check for the 'make' the user wants to use.
-AC_CHECK_PROGS(MAKE, make)
-MAKE_IS_GNU=
-case "`$MAKE --version 2>&1 | sed 1q`" in
- *GNU*)
- MAKE_IS_GNU=yes
- ;;
-esac
-AM_CONDITIONAL(GMAKE, test "$MAKE_IS_GNU" = yes)
-AC_PROG_MAKE_SET
-
# Enable gdbtk.
AC_ARG_ENABLE(gdbtk,
[ --enable-gtk enable gdbtk graphical user interface (GUI)],,