From patchwork Mon Aug 31 18:51:40 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Marchi X-Patchwork-Id: 142545 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 497634BA7984 for ; Mon, 31 Aug 2026 18:53:38 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 497634BA7984 X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from simark.ca (simark.ca [158.69.221.121]) by sourceware.org (Postfix) with ESMTPS id 89FAD4BA2E30 for ; Mon, 31 Aug 2026 18:53:06 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 89FAD4BA2E30 Authentication-Results: sourceware.org; dmarc=fail (p=none dis=none) header.from=efficios.com Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=efficios.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 89FAD4BA2E30 Authentication-Results: sourceware.org; arc=none smtp.remote-ip=158.69.221.121 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202386; cv=none; b=mOnhlSaeWKHH27mMveVCVHq68A+oF5YlqjXePx06Q09+4X56Q+aKw+pK13G9WN82UMXyGtI6cGHrkfwW7NtESYTBmnQD4tkgKuAd51kc1H74piws4D4NFBvX2PgaUT1VYtVCDcWEyeGfp0tjPW0O+MHkDuNAn58cV15tfeDSpLQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202386; c=relaxed/simple; bh=QCdDzWZ0ckL2228E3bm0hfV4r0EzYUH6STnkGoB7DJo=; h=From:To:Subject:Date:Message-ID:MIME-Version; b=G8gbJAdOLlJPk7NYj4t6SHWUqmHVN0dXqAMnfpbogY5WOPSzXt7ZQQRE/PpIpMmhqJhp4BKMCdb6+0j7r19oN8/nwO9rle1DQQqhyKppe3P8NRLuDfkXuZS2f3IXENPs1yttCeU+F+sIdM4DCOwLmuB4uzt5HmOpT4uDBeFc2pc= ARC-Authentication-Results: i=1; sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 89FAD4BA2E30 Received: by simark.ca (Postfix) id F2D2C1E0A3; Mon, 31 Aug 2026 14:53:04 -0400 (EDT) From: Simon Marchi To: gdb-patches@sourceware.org Cc: Simon Marchi Subject: [PATCH 1/7] gdb: update README about the GNU make requirement Date: Mon, 31 Aug 2026 14:51:40 -0400 Message-ID: <20260831185300.572297-2-simon.marchi@efficios.com> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260831185300.572297-1-simon.marchi@efficios.com> References: <20260831185300.572297-1-simon.marchi@efficios.com> MIME-Version: 1.0 X-Spam-Status: No, score=-1165.8 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_NONE, KAM_DMARC_STATUS, LOCAL_AUTHENTICATION_FAIL_DMARC, LOCAL_AUTHENTICATION_FAIL_SPF, SPF_HELO_PASS, SPF_SOFTFAIL, TXREP shortcircuit=no autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~patchwork=sourceware.org@sourceware.org The README still suggests that GDB can be built with a make other than GNU make, which is not the case since 2016 (f2ff9acd32b4 "Document new hard requirement on GNU make"). The manual already lists GNU make in the requirements: GNU make GDB's build system relies on features only found in the GNU make program. Other variants of make will not work. and the minimum version is documented in gdb/NEWS: * Building GDB and GDBserver now requires GNU make >= 3.82. Bring the README in line with that. - Mention the GNU make requirement, including the minimum version, near where we also state the C++17 compiler requirement. - Drop the "if your make program handles the VPATH feature correctly" part from the "Compiling GDB in another directory" section. - Drop the warning about --srcdir requiring GNU make. - Drop the "If you use GNU make" conditional from the paragraph about running the testsuite in parallel. Change-Id: I5c0387d977ab87069c01c0249c51b2f30318a0c7 Reviewed-By: Eli Zaretskii --- gdb/README | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/gdb/README b/gdb/README index 492b0891668d..791bbd23b6c2 100644 --- a/gdb/README +++ b/gdb/README @@ -82,6 +82,9 @@ list of options, invoke the subdirectory `configure', like: (Take note of how this differs from the invocation used to actually configure the build tree.) + Building GDB requires GNU make version 3.82 or later; other `make' +programs will not work. + GDB requires a C++17 compiler. If you do not have a C++17 compiler for your system, you may be able to download and install the GNU CC compiler. It is available via anonymous FTP from the @@ -254,10 +257,8 @@ Compiling GDB in another directory you need a different `gdb' compiled for each combination of host and target. `configure' is designed to make this easy by allowing you to generate each configuration in a separate subdirectory, rather than in -the source directory. If your `make' program handles the `VPATH' -feature correctly (GNU `make' and SunOS 'make' are two that should), -running `make' in each of these directories builds the `gdb' program -specified there. +the source directory. Running `make' in each of these directories +builds the `gdb' program specified there. To build `gdb' in a separate directory, run `configure' with the `--srcdir' option to specify where to find the source. (You also need @@ -367,8 +368,6 @@ more obscure GDB `configure' options are not listed here. `DIR'. `--srcdir=PATH' - *Warning: using this option requires GNU `make', or another `make' - that compatibly implements the `VPATH' feature.* Use this option to make configurations in directories separate from the GDB source directories. Among other things, you can use this to build (or maintain) several configurations simultaneously, @@ -778,8 +777,8 @@ When using a `make'-based method, you can use the Makefile variable make RUNTESTFLAGS=--directory=gdb.cp check -If you use GNU make, you can use its `-j' option to run the testsuite -in parallel. This can greatly reduce the amount of time it takes for +You can use the `-j' option of `make' to run the testsuite in +parallel. This can greatly reduce the amount of time it takes for the testsuite to run. In this case, if you set `RUNTESTFLAGS' then, by default, the tests will be run serially even under `-j'. You can override this and force a parallel run by setting the `make' variable From patchwork Mon Aug 31 18:51:41 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Marchi X-Patchwork-Id: 142547 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 34D6D4BA7994 for ; Mon, 31 Aug 2026 18:53:43 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 34D6D4BA7994 X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from simark.ca (simark.ca [158.69.221.121]) by sourceware.org (Postfix) with ESMTPS id 821654BA2E29 for ; Mon, 31 Aug 2026 18:53:06 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 821654BA2E29 Authentication-Results: sourceware.org; dmarc=fail (p=none dis=none) header.from=efficios.com Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=efficios.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 821654BA2E29 Authentication-Results: sourceware.org; arc=none smtp.remote-ip=158.69.221.121 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202386; cv=none; b=RwSwC2hwdJ+MH3vfoDEurfH5L5wPIOD/pi5F3n1UfRU5MVeGJeYP8zWAhlG8xltFjXbvWo83UX7/QRevrtYgaVmMYp0CQFD1T3z9GHHQUYE/UigSupXe6acBIE94e8Urg+s/1gKH5ZcWHLINu4PL2wqQdKwRK6FWR5q+z+B4cZ0= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202386; c=relaxed/simple; bh=blXxMJnJ4fIq5rn82/M4tqT/RMHOgi8KP4wS2c83zyk=; h=From:To:Subject:Date:Message-ID:MIME-Version; b=nnVyfbsB8JKyK57sytBh0UK6YFa9J9L+UtG3RFrLSSKi7mK419H2skYmftls46Koa6sNb2KCA3135IWokICLq1gU5G7TBU2ccMUvGj1DR9Vncw+vUe/tcnuMvGbtQA+guR3ViRbBeRdG9uWhKffUufFma4Sa7zpgHAafYqiAS2Q= ARC-Authentication-Results: i=1; sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 821654BA2E29 Received: by simark.ca (Postfix) id 2565F1E166; Mon, 31 Aug 2026 14:53:05 -0400 (EDT) From: Simon Marchi To: gdb-patches@sourceware.org Cc: Simon Marchi Subject: [PATCH 2/7] gdb, gdbserver: require gcc-style dependency generation, drop the depcomp fallback Date: Mon, 31 Aug 2026 14:51:41 -0400 Message-ID: <20260831185300.572297-3-simon.marchi@efficios.com> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260831185300.572297-1-simon.marchi@efficios.com> References: <20260831185300.572297-1-simon.marchi@efficios.com> MIME-Version: 1.0 X-Spam-Status: No, score=-1165.8 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_NONE, KAM_DMARC_STATUS, LOCAL_AUTHENTICATION_FAIL_DMARC, LOCAL_AUTHENTICATION_FAIL_SPF, SPF_HELO_PASS, SPF_SOFTFAIL, TXREP shortcircuit=no autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~patchwork=sourceware.org@sourceware.org gdb/Makefile.in and gdbserver/Makefile.in have similar code to do manual gcc3-style dependency tracking, or fallback to the depcomp tool for other dependency tracking modes. I believe that in this day and age, we can assume that all compilers we support know about gcc3-style dependency tracking. Obviously, gcc and clang both know about it. The other compilers I am aware of (I don't even know if they can build GDB) are Intel icc and IBM XL, and they both appear to have known about it for a while. I therefore propose to get rid of the fallback, which results in simpler Makefiles. In both directories, remove the depcomp fallback branch and merge the gcc3 definitions into the base COMPILE.post and POSTCOMPILE definitions. The DEPMODE and depcomp variables are not needed anymore. Remove the ZW_PROG_COMPILER_DEPENDENCIES calls in the configure.ac files, which were used to probe for the supported dependency mechanisme and substitute @CCDEPMODE@. ZW_CREATE_DEPDIR is still needed: it is what creates the top-level dependency directory from config.status. It also sets the DEPDIR variable indirectly, via AM_SET_DEPDIR. Change-Id: I2e0a42156af571e7147c83852fc9536b50af7c2e --- gdb/Makefile.in | 30 +++--------- gdb/configure | 101 +---------------------------------------- gdb/configure.ac | 1 - gdbserver/Makefile.in | 30 +++--------- gdbserver/configure | 98 --------------------------------------- gdbserver/configure.ac | 2 - 6 files changed, 16 insertions(+), 246 deletions(-) diff --git a/gdb/Makefile.in b/gdb/Makefile.in index c6bfc2949fcc..5741ee5e2e92 100644 --- a/gdb/Makefile.in +++ b/gdb/Makefile.in @@ -103,9 +103,7 @@ CXX = @CXX@ CXX_DIALECT = @CXX_DIALECT@ # Dependency tracking information. -DEPMODE = @CCDEPMODE@ DEPDIR = @DEPDIR@ -depcomp = $(SHELL) $(srcdir)/../depcomp # Directory containing source files. srcdir = @srcdir@ @@ -114,11 +112,14 @@ top_srcdir = @top_srcdir@ include $(srcdir)/silent-rules.mk -# Note that these are overridden by GNU make-specific code below if -# GNU make is used. The overrides implement dependency tracking. +# 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. COMPILE.pre = $(CXX) -x c++ $(CXX_DIALECT) -COMPILE.post = -c -o $@ -POSTCOMPILE = @true +COMPILE.post = -c -o $@ \ + -MT $@ -MMD -MP -MF $(@D)/$(DEPDIR)/$(basename $(@F)).Tpo +POSTCOMPILE = @mv $(@D)/$(DEPDIR)/$(basename $(@F)).Tpo \ + $(@D)/$(DEPDIR)/$(basename $(@F)).Po # CXXFLAGS is at the very end on purpose, so that user-supplied flags can # override internal flags. @@ -2828,23 +2829,6 @@ all_gdbtk_cflags = $(IDE_CFLAGS) $(ITCL_CFLAGS) \ # Dependency tracking. # -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. -override COMPILE.post = -c -o $@ -MT $@ -MMD -MP \ - -MF $(@D)/$(DEPDIR)/$(basename $(@F)).Tpo -override POSTCOMPILE = @mv $(@D)/$(DEPDIR)/$(basename $(@F)).Tpo \ - $(@D)/$(DEPDIR)/$(basename $(@F)).Po -else -override COMPILE.pre = source='$<' object='$@' libtool=no \ - DEPDIR=$(DEPDIR) $(DEPMODE) $(depcomp) \ - $(CXX) -x c++ $(CXX_DIALECT) -# depcomp handles atomicity for us, so we don't need a postcompile -# step. -override POSTCOMPILE = -endif - # A list of all the objects we might care about in this build, for # dependency tracking. all_object_files = gdb.o $(LIBGDB_OBS) gdbtk/generic/gdbtk-main.o diff --git a/gdb/configure b/gdb/configure index 7dc7781cb09f..94cc893a8715 100755 --- a/gdb/configure +++ b/gdb/configure @@ -795,7 +795,6 @@ SET_MAKE PKG_CONFIG_LIBDIR PKG_CONFIG_PATH PKG_CONFIG -CCDEPMODE DEPDIR am__leading_dot LTLIBXXHASH @@ -11878,7 +11877,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11881 "configure" +#line 11880 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -11984,7 +11983,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 11987 "configure" +#line 11986 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -22700,102 +22699,6 @@ DEPDIR="${am__leading_dot}deps" ac_config_commands="$ac_config_commands depdir" -depcc="$CC" am_compiler_list= - -am_depcomp=$ac_aux_dir/depcomp -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 -$as_echo_n "checking dependency style of $depcc... " >&6; } -if ${am_cv_CC_dependencies_compiler_type+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub - - am_cv_CC_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n 's/^\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` - fi - for depmode in $am_compiler_list; do - if test $depmode = none; then break; fi - - $as_echo "$as_me:$LINENO: trying $depmode" >&5 - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h - done - echo "include sub/conftest.Po" > confmf - - # We check with `-c' and `-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. - depcmd="depmode=$depmode \ - source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c" - echo "| $depcmd" | sed -e 's/ */ /g' >&5 - if env $depcmd > conftest.err 2>&1 && - grep sub/conftst6.h sub/conftest.Po >>conftest.err 2>&1 && - grep sub/conftest.${OBJEXT-o} sub/conftest.Po >>conftest.err 2>&1 && - ${MAKE-make} -s -f confmf >>conftest.err 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_CC_dependencies_compiler_type=$depmode - $as_echo "$as_me:$LINENO: success" >&5 - break - fi - fi - $as_echo "$as_me:$LINENO: failure, diagnostics are:" >&5 - sed -e 's/^/| /' < conftest.err >&5 - done - - cd .. - rm -rf conftest.dir -else - am_cv_CC_dependencies_compiler_type=none -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 -$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } -if test x${am_cv_CC_dependencies_compiler_type-none} = xnone -then as_fn_error $? "no usable dependency style found" "$LINENO" 5 -else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type - -fi - # Since the first call to PKG_CHECK_MODULES may not happen (is guarded by # a condition), we must call PKG_PROG_PKG_CONFIG explicitly to probe for diff --git a/gdb/configure.ac b/gdb/configure.ac index c70aa30fc96a..d8b2498f415b 100644 --- a/gdb/configure.ac +++ b/gdb/configure.ac @@ -61,7 +61,6 @@ GDB_AC_COMMON # Dependency checking. ZW_CREATE_DEPDIR -ZW_PROG_COMPILER_DEPENDENCIES([CC]) # Since the first call to PKG_CHECK_MODULES may not happen (is guarded by # a condition), we must call PKG_PROG_PKG_CONFIG explicitly to probe for diff --git a/gdbserver/Makefile.in b/gdbserver/Makefile.in index e45c89dc321d..b06e0b86e45b 100644 --- a/gdbserver/Makefile.in +++ b/gdbserver/Makefile.in @@ -48,9 +48,7 @@ AR_FLAGS = rc STRIP = @STRIP@ # Dependency tracking information. -DEPMODE = @CCDEPMODE@ DEPDIR = @DEPDIR@ -depcomp = $(SHELL) $(srcdir)/../depcomp # Directory containing source files. Don't clean up the spacing, # this exact string is matched for by the "configure" script. @@ -63,11 +61,14 @@ top_builddir = . include $(srcdir)/../gdb/silent-rules.mk -# Note that these are overridden by GNU make-specific code below if -# GNU make is used. The overrides implement dependency tracking. +# 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. COMPILE.pre = $(CXX) $(CXX_DIALECT) -COMPILE.post = -c -o $@ -POSTCOMPILE = @true +COMPILE.post = -c -o $@ \ + -MT $@ -MMD -MP -MF $(@D)/$(DEPDIR)/$(basename $(@F)).Tpo +POSTCOMPILE = @mv $(@D)/$(DEPDIR)/$(basename $(@F)).Tpo \ + $(@D)/$(DEPDIR)/$(basename $(@F)).Po INCLUDE_SERVER_H = -include $(srcdir)/server.h @@ -596,23 +597,6 @@ gdbreplay.o: gdbreplay.cc # Dependency tracking. # -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. -override COMPILE.post = -c -o $@ -MT $@ -MMD -MP \ - -MF $(@D)/$(DEPDIR)/$(basename $(@F)).Tpo -override POSTCOMPILE = @mv $(@D)/$(DEPDIR)/$(basename $(@F)).Tpo \ - $(@D)/$(DEPDIR)/$(basename $(@F)).Po -else -override COMPILE.pre = source='$<' object='$@' libtool=no \ - DEPDIR=$(DEPDIR) $(DEPMODE) $(depcomp) \ - $(CXX) $(CXX_DIALECT) -# depcomp handles atomicity for us, so we don't need a postcompile -# step. -override POSTCOMPILE = -endif - # A list of all the objects we might care about in this build, for # dependency tracking. all_object_files = $(OBS) $(GDBREPLAY_OBS) $(IPA_OBJS) diff --git a/gdbserver/configure b/gdbserver/configure index 46faecc3a207..3cf8df2c3ae1 100755 --- a/gdbserver/configure +++ b/gdbserver/configure @@ -637,7 +637,6 @@ REPORT_BUGS_TO PKGVERSION WERROR_CFLAGS WARN_CFLAGS -CCDEPMODE CONFIG_SRC_SUBDIR CATOBJEXT GENCAT @@ -12821,103 +12820,6 @@ CONFIG_SRC_SUBDIR="arch gdbsupport nat target" ac_config_commands="$ac_config_commands gdbdepdir" -depcc="$CC" am_compiler_list= - -am_depcomp=$ac_aux_dir/depcomp -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 -$as_echo_n "checking dependency style of $depcc... " >&6; } -if ${am_cv_CC_dependencies_compiler_type+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub - - am_cv_CC_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n 's/^\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` - fi - for depmode in $am_compiler_list; do - if test $depmode = none; then break; fi - - $as_echo "$as_me:$LINENO: trying $depmode" >&5 - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h - done - echo "include sub/conftest.Po" > confmf - - # We check with `-c' and `-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. - depcmd="depmode=$depmode \ - source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c" - echo "| $depcmd" | sed -e 's/ */ /g' >&5 - if env $depcmd > conftest.err 2>&1 && - grep sub/conftst6.h sub/conftest.Po >>conftest.err 2>&1 && - grep sub/conftest.${OBJEXT-o} sub/conftest.Po >>conftest.err 2>&1 && - ${MAKE-make} -s -f confmf >>conftest.err 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_CC_dependencies_compiler_type=$depmode - $as_echo "$as_me:$LINENO: success" >&5 - break - fi - fi - $as_echo "$as_me:$LINENO: failure, diagnostics are:" >&5 - sed -e 's/^/| /' < conftest.err >&5 - done - - cd .. - rm -rf conftest.dir -else - am_cv_CC_dependencies_compiler_type=none -fi - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 -$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } -if test x${am_cv_CC_dependencies_compiler_type-none} = xnone -then as_fn_error $? "no usable dependency style found" "$LINENO" 5 -else CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type - -fi - - for ac_header in \ arpa/inet.h \ fcntl.h \ diff --git a/gdbserver/configure.ac b/gdbserver/configure.ac index 9979afe7ece9..a549a8712fc1 100644 --- a/gdbserver/configure.ac +++ b/gdbserver/configure.ac @@ -76,8 +76,6 @@ AC_CONFIG_COMMANDS([gdbdepdir],[ done], [ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR CONFIG_SRC_SUBDIR="$CONFIG_SRC_SUBDIR"]) -ZW_PROG_COMPILER_DEPENDENCIES([CC]) - AC_CHECK_HEADERS([ \ arpa/inet.h \ fcntl.h \ From patchwork Mon Aug 31 18:51:42 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Marchi X-Patchwork-Id: 142544 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 2F7364BA903A for ; Mon, 31 Aug 2026 18:53:36 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 2F7364BA903A X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from simark.ca (simark.ca [158.69.221.121]) by sourceware.org (Postfix) with ESMTPS id 8A1FF4BA2E38 for ; Mon, 31 Aug 2026 18:53:06 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 8A1FF4BA2E38 Authentication-Results: sourceware.org; dmarc=fail (p=none dis=none) header.from=efficios.com Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=efficios.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 8A1FF4BA2E38 Authentication-Results: sourceware.org; arc=none smtp.remote-ip=158.69.221.121 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202386; cv=none; b=cfxbJhceuO765+7Q9d4VF3WSnzYEZUY7/hd2PR5paRyAsX63RIXE/isj6sY1k3WANqZikFE1yD/owaWI+2FdkWu2GEHnTZq1SbDkJlKNftBeXigRfgwLoxT3o616cZCrVK3vNMuQdv9Y6Iv/PqzIMk7sdq9eOoOgrdIfbTYeTB0= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202386; c=relaxed/simple; bh=LFmS0SVDAgop4SUpz2aUbnWF9BIX4/HUBi+ot1wUty8=; h=From:To:Subject:Date:Message-ID:MIME-Version; b=cYHKZpR3sYfcNa6rDtr1KnlXAnoSmfSeLSyWl5ZElsWVDO6hxW/j0m4nC5nXw0ifkS08pdsph4AqnpUiGshF6C7EGb4Pn6Z/BhdLLJu5+9gfX7zjCc2rV6y86jdf08dVtxqZpbjuQ/UeJ117R2/nKU2tCGETnx58MIYnMOkBS5M= ARC-Authentication-Results: i=1; sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8A1FF4BA2E38 Received: by simark.ca (Postfix) id 3AE101E167; Mon, 31 Aug 2026 14:53:05 -0400 (EDT) From: Simon Marchi To: gdb-patches@sourceware.org Cc: Simon Marchi Subject: [PATCH 3/7] gdbserver: fix missing dependency tracking for gdbreplay.o Date: Mon, 31 Aug 2026 14:51:42 -0400 Message-ID: <20260831185300.572297-4-simon.marchi@efficios.com> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260831185300.572297-1-simon.marchi@efficios.com> References: <20260831185300.572297-1-simon.marchi@efficios.com> MIME-Version: 1.0 X-Spam-Status: No, score=-1165.8 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_NONE, KAM_DMARC_STATUS, LOCAL_AUTHENTICATION_FAIL_DMARC, LOCAL_AUTHENTICATION_FAIL_SPF, SPF_HELO_PASS, SPF_SOFTFAIL, TXREP shortcircuit=no autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~patchwork=sourceware.org@sourceware.org The rule for gdbreplay.o uses $(COMPILE.post), which makes the compiler write the dependencies to $(DEPDIR)/gdbreplay.Tpo, but it does not run $(POSTCOMPILE), which is what renames the .Tpo file to .Po. After building gdbreplay, we are left with: $ make gdbreplay CXX gdbreplay.o CXX utils.o GEN version-generated.cc CXX version.o CXXLD gdbreplay /0.1s $ ls -1 .deps gdbreplay.Tpo utils.Po version.Po This means that a change in a header file included by gdbreplay.cc will not cause a rebuild. Add the missing $(POSTCOMPILE) invocation. Change-Id: Iea5ca939cf30a0fe892ed3d2c224d22f227f0272 --- gdbserver/Makefile.in | 1 + 1 file changed, 1 insertion(+) diff --git a/gdbserver/Makefile.in b/gdbserver/Makefile.in index b06e0b86e45b..3a3c8e62d14f 100644 --- a/gdbserver/Makefile.in +++ b/gdbserver/Makefile.in @@ -592,6 +592,7 @@ target/%.o: ../gdb/target/%.c gdbreplay.o: gdbreplay.cc $(ECHO_CXX) $(COMPILE.pre) $(INTERNAL_CFLAGS) $(CXXFLAGS) \ -include gdbsupport/common-defs.h $(COMPILE.post) $< + $(POSTCOMPILE) # # Dependency tracking. From patchwork Mon Aug 31 18:51:43 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Marchi X-Patchwork-Id: 142548 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id BC70C4BA7995 for ; Mon, 31 Aug 2026 18:54:09 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org BC70C4BA7995 X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from simark.ca (simark.ca [158.69.221.121]) by sourceware.org (Postfix) with ESMTPS id 4E1CA4BA23C4 for ; Mon, 31 Aug 2026 18:53:07 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 4E1CA4BA23C4 Authentication-Results: sourceware.org; dmarc=fail (p=none dis=none) header.from=efficios.com Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=efficios.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 4E1CA4BA23C4 Authentication-Results: sourceware.org; arc=none smtp.remote-ip=158.69.221.121 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202387; cv=none; b=OVMdd1U9jsCCAC5SO34ylTXfuTfJJIg8+bpIQbbppLgx1qNJyVMQdvycpuXj3Eejgpfq1BKByxpw9stqNB8kFzsVnh53sMw3cLDW419HryK2MwQ53xdAweuiR9joMLDD1kONYMi+6gGbf24AhGiTy7uK9ogirjzwyTFGETJ8dJk= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202387; c=relaxed/simple; bh=0eUnB4jRajbuhps7383Ald/ABTi6ULTkFQRqnsMXaMw=; h=From:To:Subject:Date:Message-ID:MIME-Version; b=K8JKhJycbVn4x/exPa/WXL6p7bI2gvj+Na1h6IJL1nMt8vOtlND2eFSS6z5KnDagTPIQ2ey0KZsGLfOwxB5ELP5mH5+lzFIH474pdu/gN9HXDIcvXr7tKgK05rrqs0KvrdHpcwpa9vw7b5KJlI5BbUHsV4O/M31CW9/tRhtaK9Y= ARC-Authentication-Results: i=1; sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4E1CA4BA23C4 Received: by simark.ca (Postfix) id B40871E168; Mon, 31 Aug 2026 14:53:05 -0400 (EDT) From: Simon Marchi To: gdb-patches@sourceware.org Cc: Simon Marchi Subject: [PATCH 4/7] gdb, gdbserver: always use order-only prerequisites for generated files Date: Mon, 31 Aug 2026 14:51:43 -0400 Message-ID: <20260831185300.572297-5-simon.marchi@efficios.com> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260831185300.572297-1-simon.marchi@efficios.com> References: <20260831185300.572297-1-simon.marchi@efficios.com> MIME-Version: 1.0 X-Spam-Status: No, score=-1165.8 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_NONE, KAM_DMARC_STATUS, LOCAL_AUTHENTICATION_FAIL_DMARC, LOCAL_AUTHENTICATION_FAIL_SPF, SPF_HELO_PASS, SPF_SOFTFAIL, TXREP shortcircuit=no autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~patchwork=sourceware.org@sourceware.org Both gdb/Makefile.in and gdbserver/Makefile.in guard their use of order-only prerequisites behind a check for the .VARIABLES variable, falling back to a normal prerequisite when it is not defined: # 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. ifdef .VARIABLES $(all_object_files): | $(generated_files) else $(all_object_files) : $(generated_files) endif Building GDB requires GNU make >= 3.82, as documented in gdb/NEWS and (as of the previous patch) in gdb/README. On top of that, gdb/Makefile.in already uses an order-only prerequisite unconditionally, in the rule for compiling .c files in the top-level gdb directory: %.o: %.c | $(CONFIG_DEP_SUBDIR) Remove the conditional and trim the comment accordingly. Change-Id: Ic5cca15f21dc1a4908f978c788f416780ea1b5cd --- gdb/Makefile.in | 8 +------- gdbserver/Makefile.in | 8 +------- 2 files changed, 2 insertions(+), 14 deletions(-) diff --git a/gdb/Makefile.in b/gdb/Makefile.in index 5741ee5e2e92..cdf73ec708e0 100644 --- a/gdb/Makefile.in +++ b/gdb/Makefile.in @@ -2837,14 +2837,8 @@ all_object_files = gdb.o $(LIBGDB_OBS) gdbtk/generic/gdbtk-main.o all_deps_files = $(foreach dep,$(patsubst %.o,%.Po,$(all_object_files)),\ $(dir $(dep))/$(DEPDIR)/$(notdir $(dep))) -# 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. -ifdef .VARIABLES +# Ensure that generated files are created early. $(all_object_files): | $(generated_files) -else -$(all_object_files) : $(generated_files) -endif # Dependencies. -include $(all_deps_files) diff --git a/gdbserver/Makefile.in b/gdbserver/Makefile.in index 3a3c8e62d14f..7c6ab64196e2 100644 --- a/gdbserver/Makefile.in +++ b/gdbserver/Makefile.in @@ -602,14 +602,8 @@ gdbreplay.o: gdbreplay.cc # dependency tracking. 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. -ifdef .VARIABLES +# Ensure that generated files are created early. $(all_object_files): | $(generated_files) -else -$(all_object_files) : $(generated_files) -endif # All the .deps files to include. all_deps_files = $(foreach dep,$(patsubst %.o,%.Po,$(all_object_files)),\ From patchwork Mon Aug 31 18:51:44 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Marchi X-Patchwork-Id: 142546 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 343864B9DB4F for ; Mon, 31 Aug 2026 18:53:39 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 343864B9DB4F X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from simark.ca (simark.ca [158.69.221.121]) by sourceware.org (Postfix) with ESMTPS id C36E84BA2E2B for ; Mon, 31 Aug 2026 18:53:10 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org C36E84BA2E2B Authentication-Results: sourceware.org; dmarc=fail (p=none dis=none) header.from=efficios.com Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=efficios.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org C36E84BA2E2B Authentication-Results: sourceware.org; arc=none smtp.remote-ip=158.69.221.121 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202390; cv=none; b=c5sDZsnum7iMqJJoCT6XY5xJGiDeEWkAVacjCTlZGpsG204PRkCEdWaOzpEjd9vNGVhY1IRMfP/GbeJBjgevZtn2VlLbpJOCqyWQ7sz3T0HI4xyBkARuvHWV2bk13pahbunDlK2Zyu3pUSN5FVZ1wKDz7V5d3BL5Ulpc0T7Iuf0= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202390; c=relaxed/simple; bh=ow2HTvYe/yDcw7LSObX6z5LYPR+WRYUpLNSsnPhJ2Uw=; h=From:To:Subject:Date:Message-ID:MIME-Version; b=GDgPXGCfxmTdgeDYgRP4SFLxJ3/cHe+/prvvCwuGCjN32w4nWlRduJhRHo5P1hel4HaCOuaR6E0nTk2NlmQ5U92O3T4LDEeBnhNeWn4ODtb/u8FwA0jflf0Q+nALNEWjz6XcJJPnBMafTbuNQs3C1S1eUgVFRINPRKgAE9bWGQ0= ARC-Authentication-Results: i=1; sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org C36E84BA2E2B Received: by simark.ca (Postfix) id C61E71E16F; Mon, 31 Aug 2026 14:53:05 -0400 (EDT) From: Simon Marchi To: gdb-patches@sourceware.org Cc: Simon Marchi Subject: [PATCH 5/7] gdb, gdbserver: remove the .NOEXPORT target Date: Mon, 31 Aug 2026 14:51:44 -0400 Message-ID: <20260831185300.572297-6-simon.marchi@efficios.com> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260831185300.572297-1-simon.marchi@efficios.com> References: <20260831185300.572297-1-simon.marchi@efficios.com> MIME-Version: 1.0 X-Spam-Status: No, score=-1165.8 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_NONE, KAM_DMARC_STATUS, LOCAL_AUTHENTICATION_FAIL_DMARC, LOCAL_AUTHENTICATION_FAIL_SPF, SPF_HELO_PASS, SPF_SOFTFAIL, TXREP shortcircuit=no autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~patchwork=sourceware.org@sourceware.org gdb/Makefile.in and gdbserver/Makefile.in both contain: # GNU Make has an annoying habit of putting *all* the Makefile variables # into the environment, unless you include this target as a circumvention. # Rumor is that this will be fixed (and this target can be removed) # in GNU Make 4.0. .NOEXPORT: This was introduced in gdb in commit 625453dcfda0 ("Merge in irix support", 1991-08-31), and copied to gdbserver's Makefile.in when it was created, in commit c033ec179a2a (1993-08-27). It was a legitimate workaround at the time, but only for a few months. GNU make commit b8d48ad379dc, from 1992-05-03, removed the handling of .NOEXPORT: - int noexport = enter_file (".NOEXPORT")->is_target; ... - /* If `.NOEXPORT' was specified, only export command-line and - environment variables. This is a temporary (very ugly) hack - until I fix this problem the right way in version 4. Ick. */ So .NOEXPORT has done nothing for any GNU make for a very long time, remove it. Change-Id: I173807df18447d3ae2f6728ccb711d43d1f9d307 --- gdb/Makefile.in | 6 ------ gdbserver/Makefile.in | 6 ------ 2 files changed, 12 deletions(-) diff --git a/gdb/Makefile.in b/gdb/Makefile.in index cdf73ec708e0..74361808bf5a 100644 --- a/gdb/Makefile.in +++ b/gdb/Makefile.in @@ -2604,12 +2604,6 @@ gdb.cxref: $(SFILES) force_update: -# GNU Make has an annoying habit of putting *all* the Makefile variables -# into the environment, unless you include this target as a circumvention. -# Rumor is that this will be fixed (and this target can be removed) -# in GNU Make 4.0. -.NOEXPORT: - # GNU Make 3.63 has a different problem: it keeps tacking command line # overrides onto the definition of $(MAKE). This variable setting # will remove them. diff --git a/gdbserver/Makefile.in b/gdbserver/Makefile.in index 7c6ab64196e2..5054597bf6ef 100644 --- a/gdbserver/Makefile.in +++ b/gdbserver/Makefile.in @@ -473,12 +473,6 @@ stamp-xml: $(XML_DIR)/feature_to_c.sh Makefile $(XML_FILES) .PRECIOUS: xml-builtin.cc -# GNU Make has an annoying habit of putting *all* the Makefile variables -# into the environment, unless you include this target as a circumvention. -# Rumor is that this will be fixed (and this target can be removed) -# in GNU Make 4.0. -.NOEXPORT: - # GNU Make 3.63 has a different problem: it keeps tacking command line # overrides onto the definition of $(MAKE). This variable setting # will remove them. From patchwork Mon Aug 31 18:51:45 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Marchi X-Patchwork-Id: 142549 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 30ADD4BA23ED for ; Mon, 31 Aug 2026 18:54:13 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 30ADD4BA23ED X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from simark.ca (simark.ca [158.69.221.121]) by sourceware.org (Postfix) with ESMTPS id 10CF64BA23DE for ; Mon, 31 Aug 2026 18:53:11 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 10CF64BA23DE Authentication-Results: sourceware.org; dmarc=fail (p=none dis=none) header.from=efficios.com Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=efficios.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 10CF64BA23DE Authentication-Results: sourceware.org; arc=none smtp.remote-ip=158.69.221.121 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202391; cv=none; b=BGmR7S1OQ18W0p0u2y1ySnUael1wTPWpWtVwiFfjNAqi34lxtkcjX33UYvSjQrf0tcbVtXY1zhHHayk+Dr0hfhGhewT5GRJOBjMS/N+TkyeXh6g5zUtw7dQLuauh6WYZ++GA4sTcNE73e++trYdhnHeZdJ165mmVdzqUGP+bGDY= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202391; c=relaxed/simple; bh=pBWKAr11X8osJGqx6g3s+uW0geZUz4kz8u2dPAJ2xW4=; h=From:To:Subject:Date:Message-ID:MIME-Version; b=EmZCFh0LvHiw70XerJR6q5D6IRJE5v9cUUJVZZrqgJn3bYuYEAWXpzOII7XdJaNng/XExJ52/h1fSzmbDD4oTBiI8tJPcSZ2PymTwQEvE/IzjcLgqEDDtbtWw7WTzHZyYHUuarmmGmIQvQojeDzuN92VuO3kYIhgNNvHYRBn648= ARC-Authentication-Results: i=1; sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 10CF64BA23DE Received: by simark.ca (Postfix) id CC2451E171; Mon, 31 Aug 2026 14:53:05 -0400 (EDT) From: Simon Marchi To: gdb-patches@sourceware.org Cc: Simon Marchi Subject: [PATCH 6/7] gdb: remove the explicit ada-exp.o rule Date: Mon, 31 Aug 2026 14:51:45 -0400 Message-ID: <20260831185300.572297-7-simon.marchi@efficios.com> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260831185300.572297-1-simon.marchi@efficios.com> References: <20260831185300.572297-1-simon.marchi@efficios.com> MIME-Version: 1.0 X-Spam-Status: No, score=-1165.8 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_NONE, KAM_DMARC_STATUS, LOCAL_AUTHENTICATION_FAIL_DMARC, LOCAL_AUTHENTICATION_FAIL_SPF, SPF_HELO_PASS, SPF_SOFTFAIL, TXREP shortcircuit=no autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~patchwork=sourceware.org@sourceware.org gdb/Makefile.in has an explicit rule to build ada-exp.o, along with an ADA_EXP_C variable used to spell out which ada-exp.c to compile: # ada-exp.c can appear in srcdir, for releases; or in ., for # development builds. ADA_EXP_C = `if test -f ada-exp.c; then echo ada-exp.c; else echo $(srcdir)/ada-exp.c; fi` ada-exp.o: ada-exp.c $(COMPILE) $(ADA_EXP_C) $(POSTCOMPILE) I don't think that's needed today. Both were added by commit 94e36acc3c80 (2013-07-10), the point was to compile ada-exp.c with -Wno-old-style-definition. Commit 8dc9fd87b096 ("Simplify ada-exp.o rule", 2018-09-01) dropped -Wold-style-definition, since it has no meaning in C++. That removed the reason for the rule to exist, but the rule was kept, on the grounds that "according to the comment, ada-exp.c may appear in the srcdir". But this is already by make: srcdir is in VPATH, so the pattern rule finds ada-exp.c in the build directory if it is there, and in srcdir otherwise. It works for all other *-exp.c files. Remove the rule and ADA_EXP_C, and let the generic pattern rule handle ada-exp.o. Remove the comment introducing the section as well, as this was the last rule in it. Tested in a development build only, we'll need to test this when building from a tarball, but that will be done at release time. Change-Id: Icec556845abe405cd51c8ba2999d7af9ee64db20 --- gdb/Makefile.in | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/gdb/Makefile.in b/gdb/Makefile.in index 74361808bf5a..cf10bc17320b 100644 --- a/gdb/Makefile.in +++ b/gdb/Makefile.in @@ -2609,17 +2609,6 @@ force_update: # will remove them. MAKEOVERRIDES = -# Some files need explicit build rules (due to -Werror problems) or due -# to sub-directory fun 'n' games. - -# ada-exp.c can appear in srcdir, for releases; or in ., for -# development builds. -ADA_EXP_C = `if test -f ada-exp.c; then echo ada-exp.c; else echo $(srcdir)/ada-exp.c; fi` - -ada-exp.o: ada-exp.c - $(COMPILE) $(ADA_EXP_C) - $(POSTCOMPILE) - # Message files. Based on code in gcc/Makefile.in. # Rules for generating translated message descriptions. Disabled by From patchwork Mon Aug 31 18:51:46 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Marchi X-Patchwork-Id: 142550 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 7B7BC4BA23DE for ; Mon, 31 Aug 2026 18:54:48 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 7B7BC4BA23DE X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from simark.ca (simark.ca [158.69.221.121]) by sourceware.org (Postfix) with ESMTPS id D58414BA2E38 for ; Mon, 31 Aug 2026 18:53:10 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org D58414BA2E38 Authentication-Results: sourceware.org; dmarc=fail (p=none dis=none) header.from=efficios.com Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=efficios.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org D58414BA2E38 Authentication-Results: sourceware.org; arc=none smtp.remote-ip=158.69.221.121 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202391; cv=none; b=FcQcZL1AW8LRE6A4u/wuYxy4NqxJC+h9zanPy8p/03Oieuml9CGGw02U4EYSME+rVAUC1lybGCtw/VCmg8yuLXBnU6vG/QaFSNJ+k/oeL0NoZa2wnsNheuYOk3Am3RzJAWor33jnEI4IuU1Bm3Ff1v+OIQk47fBDm1kiEDfclf8= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1788202391; c=relaxed/simple; bh=+gEdjpK10zBTOxiqzvqFucVfarIpSRv0ftdK1qLGYUk=; h=From:To:Subject:Date:Message-ID:MIME-Version; b=GNP8HVSQ4txmfr3UKktBi6eM9PGaQ3SP/ZZ7tJrTMQ08mP2rQfDEaQcDphv6DSp8kZTmXOvZNfZsfM9RswChDQP4ZKtvwxDeWJOeAEIM0yBGrme/TiTTpLX5Z42wHcE8pUfbDSKs0zfy48WzI+JEKvt4Bl1RfAtAr4zdsRPLGeQ= ARC-Authentication-Results: i=1; sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org D58414BA2E38 Received: by simark.ca (Postfix) id DC9451E173; Mon, 31 Aug 2026 14:53:05 -0400 (EDT) From: Simon Marchi To: gdb-patches@sourceware.org Cc: Simon Marchi Subject: [PATCH 7/7] gdb, gdbserver: create the dependency directories from the Makefiles Date: Mon, 31 Aug 2026 14:51:46 -0400 Message-ID: <20260831185300.572297-8-simon.marchi@efficios.com> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260831185300.572297-1-simon.marchi@efficios.com> References: <20260831185300.572297-1-simon.marchi@efficios.com> MIME-Version: 1.0 X-Spam-Status: No, score=-1165.8 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_NONE, KAM_DMARC_STATUS, LOCAL_AUTHENTICATION_FAIL_DMARC, LOCAL_AUTHENTICATION_FAIL_SPF, SPF_HELO_PASS, SPF_SOFTFAIL, TXREP shortcircuit=no autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~patchwork=sourceware.org@sourceware.org Some .deps directories are created at configure time: - gdb/configure.ac and gdbserver/configure.ac call ZW_CREATE_DEPDIR, which creates the top-level one from config.status. - gdbserver/configure.ac has an additional AC_CONFIG_COMMANDS to create the .deps dirs for its subdirectories listed in CONFIG_SRC_SUBDIR (arch, gdbsupport, nat and target). Meanwhile, gdb creates the sub-directory ones from the Makefile, through an order-only prerequisite on the rule for compiling .c files. If the user deletes a .deps directory created by configure (config.status, really), then the build breaks: $ rm -rf gdb/.deps $ make CXX gdb.o gdb.c:39:1: fatal error: opening dependency file ./.deps/gdb.Tpo: No such file or directory On the other hand, it works for those .deps created by a Makefile (they are re-created as needed). This patch changes how we create .deps directories to make it simpler, more robust and consistent. In both gdb and gdbserver: - Add an ALL_DEPDIRS variable, listing the .deps directories, and a rule to create them. - Make ALL_DEPDIRS an order-only prerequisite of $(all_object_files), such that the .deps directories will be created before compiling any .o file. - Since we now have a variable (ALL_DEPDIRS) listing all .deps directories, use it where convenient in the clean and distclean targets. Note that this changes the command to create directories from "$(SHELL) $(srcdir)/../install-sh -d" to "mkdir -p". If there is a reason to use install-sh to create directories in the build directory, I think it should be documented, otherwise it just looks strange. The configure-time creation is not needed anymore. Replace the ZW_CREATE_DEPDIR calls with AM_SET_DEPDIR, which is what actually provides DEPDIR, and drop gdbserver's gdbdepdir AC_CONFIG_COMMANDS. That leaves gdbserver's CONFIG_SRC_SUBDIR with no user in configure, so define it directly in gdbserver/Makefile.in, like gdb already does. Change-Id: I71e76a9a37a525f58c9c66e5556e8da965cc2ca3 --- gdb/Makefile.in | 33 +++++++++++++++------------------ gdb/configure | 6 ------ gdb/configure.ac | 2 +- gdbserver/Makefile.in | 25 ++++++++++++++----------- gdbserver/configure | 21 --------------------- gdbserver/configure.ac | 13 +------------ 6 files changed, 31 insertions(+), 69 deletions(-) diff --git a/gdb/Makefile.in b/gdb/Makefile.in index cf10bc17320b..3585f2015ff0 100644 --- a/gdb/Makefile.in +++ b/gdb/Makefile.in @@ -590,7 +590,6 @@ HAVE_GSTACK = @HAVE_GSTACK@ CONFIG_SRC_SUBDIR = arch cli dwarf2 mi compile tui unittests guile python \ target nat gdbtk/generic -CONFIG_DEP_SUBDIR = $(addsuffix /$(DEPDIR),$(CONFIG_SRC_SUBDIR)) # -I. for config files. # -I$(srcdir) for gdb internal headers. @@ -2092,15 +2091,11 @@ PYTHON_CFLAGS = @PYTHON_CFLAGS@ all: gdb$(EXEEXT) $(CONFIG_ALL) gdb-gdb.gdb gcore gstack gdb-add-index @$(MAKE) $(FLAGS_TO_PASS) DO=all "DODIRS=$(SUBDIRS)" subdir_do -# Rule for compiling .c files in the top-level gdb directory. -# The order-only dependencies ensure that we create the build subdirectories. -%.o: %.c | $(CONFIG_DEP_SUBDIR) +# Rule for compiling .c files. +%.o: %.c $(COMPILE) $< $(POSTCOMPILE) -$(CONFIG_DEP_SUBDIR): - $(ECHO_GEN) $(SHELL) $(srcdir)/../install-sh -d $@ - # Python files need special flags. python/%.o: INTERNAL_CFLAGS += $(PYTHON_CFLAGS) @@ -2413,11 +2408,8 @@ clean mostlyclean: $(CONFIG_CLEAN) rm -f gdb$(EXEEXT) core make.log rm -f gdb[0-9]$(EXEEXT) rm -f xml-builtin.c stamp-xml - rm -f $(DEPDIR)/* - for i in $(CONFIG_SRC_SUBDIR); do \ - rm -f $$i/*.o; \ - rm -f $$i/$(DEPDIR)/*; \ - done + rm -f $(addsuffix /*,$(ALL_DEPDIRS)) + rm -f $(addsuffix /*.o,$(CONFIG_SRC_SUBDIR)) # This used to depend on c-exp.c m2-exp.c TAGS # I believe this is wrong; the makefile standards for distclean just @@ -2431,10 +2423,7 @@ distclean: clean rm -f config.log config.cache rm -f config.lt libtool rm -f Makefile - rm -rf $(DEPDIR) - for i in $(CONFIG_SRC_SUBDIR); do \ - if test -d $$i/$(DEPDIR); then rmdir $$i/$(DEPDIR); fi \ - done + rm -rf $(ALL_DEPDIRS) maintainer-clean: local-maintainer-clean do-maintainer-clean distclean realclean: maintainer-clean @@ -2816,12 +2805,20 @@ all_gdbtk_cflags = $(IDE_CFLAGS) $(ITCL_CFLAGS) \ # dependency tracking. all_object_files = gdb.o $(LIBGDB_OBS) gdbtk/generic/gdbtk-main.o +# All the directories in which we put dependency files. +ALL_DEPDIRS = $(DEPDIR) $(addsuffix /$(DEPDIR),$(CONFIG_SRC_SUBDIR)) + +$(ALL_DEPDIRS): + $(ECHO_GEN) mkdir -p $@ + # All the .deps files to include. all_deps_files = $(foreach dep,$(patsubst %.o,%.Po,$(all_object_files)),\ $(dir $(dep))/$(DEPDIR)/$(notdir $(dep))) -# Ensure that generated files are created early. -$(all_object_files): | $(generated_files) +# Ensure that the generated files and the dependency directories are created +# early. Creating a dependency directory also creates the directory the +# objects go in. +$(all_object_files): | $(generated_files) $(ALL_DEPDIRS) # Dependencies. -include $(all_deps_files) diff --git a/gdb/configure b/gdb/configure index 94cc893a8715..4078a8af9f4a 100755 --- a/gdb/configure +++ b/gdb/configure @@ -22696,9 +22696,6 @@ rmdir .tst 2>/dev/null DEPDIR="${am__leading_dot}deps" -ac_config_commands="$ac_config_commands depdir" - - # Since the first call to PKG_CHECK_MODULES may not happen (is guarded by # a condition), we must call PKG_PROG_PKG_CONFIG explicitly to probe for @@ -34692,7 +34689,6 @@ fi ac_aux_dir='$ac_aux_dir' -ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR # Capture the value of obsolete ALL_LINGUAS because we need it to compute # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it # from automake. @@ -34712,7 +34708,6 @@ do case $ac_config_target in "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;; "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; - "depdir") CONFIG_COMMANDS="$CONFIG_COMMANDS depdir" ;; "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;; "jit-reader.h") CONFIG_FILES="$CONFIG_FILES jit-reader.h:jit-reader.in" ;; "nm.h") CONFIG_LINKS="$CONFIG_LINKS nm.h:$GDB_NM_FILE" ;; @@ -36161,7 +36156,6 @@ compiler_lib_search_path=$lt_compiler_lib_search_path_CXX _LT_EOF ;; - "depdir":C) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;; "default-1":C) for ac_file in $CONFIG_FILES; do # Support "outfile[:infile[:infile...]]" diff --git a/gdb/configure.ac b/gdb/configure.ac index d8b2498f415b..f15a2e16947c 100644 --- a/gdb/configure.ac +++ b/gdb/configure.ac @@ -60,7 +60,7 @@ AX_CXX_COMPILE_STDCXX(17, , mandatory) GDB_AC_COMMON # Dependency checking. -ZW_CREATE_DEPDIR +AM_SET_DEPDIR # Since the first call to PKG_CHECK_MODULES may not happen (is guarded by # a condition), we must call PKG_PROG_PKG_CONFIG explicitly to probe for diff --git a/gdbserver/Makefile.in b/gdbserver/Makefile.in index 5054597bf6ef..9417a93268cd 100644 --- a/gdbserver/Makefile.in +++ b/gdbserver/Makefile.in @@ -27,7 +27,7 @@ program_transform_name = @program_transform_name@ bindir = @bindir@ libdir = @libdir@ -CONFIG_SRC_SUBDIR = @CONFIG_SRC_SUBDIR@ +CONFIG_SRC_SUBDIR = arch gdbsupport nat target install_sh = @install_sh@ @@ -428,17 +428,12 @@ mostlyclean clean: rm -f $(IPA_LIB) rm -f *-generated.cc rm -f stamp-xml - rm -f $(DEPDIR)/*.Po - for i in $(CONFIG_SRC_SUBDIR); do \ - rm -f $$i/*.o; \ - rm -f $$i/$(DEPDIR)/*; \ - done + rm -f $(addsuffix /*,$(ALL_DEPDIRS)) + rm -f $(addsuffix /*.o,$(CONFIG_SRC_SUBDIR)) maintainer-clean realclean distclean: clean rm -f Makefile config.status config.h stamp-h config.log config.cache - for i in $(CONFIG_SRC_SUBDIR); do \ - rmdir $$i/$(DEPDIR); \ - done + rm -rf $(ALL_DEPDIRS) config.h: stamp-h ; @true stamp-h: config.in config.status @@ -596,8 +591,16 @@ gdbreplay.o: gdbreplay.cc # dependency tracking. all_object_files = $(OBS) $(GDBREPLAY_OBS) $(IPA_OBJS) -# Ensure that generated files are created early. -$(all_object_files): | $(generated_files) +# All the directories in which we put dependency files. +ALL_DEPDIRS = $(DEPDIR) $(addsuffix /$(DEPDIR),$(CONFIG_SRC_SUBDIR)) + +$(ALL_DEPDIRS): + $(ECHO_GEN) mkdir -p $@ + +# Ensure that the generated files and the dependency directories are created +# early. Creating a dependency directory also creates the directory the +# objects go in. +$(all_object_files): | $(generated_files) $(ALL_DEPDIRS) # All the .deps files to include. all_deps_files = $(foreach dep,$(patsubst %.o,%.Po,$(all_object_files)),\ diff --git a/gdbserver/configure b/gdbserver/configure index 3cf8df2c3ae1..dd749fcb55bc 100755 --- a/gdbserver/configure +++ b/gdbserver/configure @@ -637,7 +637,6 @@ REPORT_BUGS_TO PKGVERSION WERROR_CFLAGS WARN_CFLAGS -CONFIG_SRC_SUBDIR CATOBJEXT GENCAT INSTOBJEXT @@ -10956,9 +10955,6 @@ rmdir .tst 2>/dev/null DEPDIR="${am__leading_dot}deps" -ac_config_commands="$ac_config_commands depdir" - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } @@ -12813,13 +12809,6 @@ $as_echo "$LINGUAS" >&6; } fi -# Create sub-directories for objects and dependencies. -CONFIG_SRC_SUBDIR="arch gdbsupport nat target" - - -ac_config_commands="$ac_config_commands gdbdepdir" - - for ac_header in \ arpa/inet.h \ fcntl.h \ @@ -15459,7 +15448,6 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # # INIT-COMMANDS # -ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR # Capture the value of obsolete ALL_LINGUAS because we need it to compute # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it # from automake. @@ -15467,7 +15455,6 @@ ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR # Capture the value of LINGUAS because we need it to compute CATALOGS. LINGUAS="${LINGUAS-%UNSET%}" -ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR CONFIG_SRC_SUBDIR="$CONFIG_SRC_SUBDIR" _ACEOF @@ -15478,9 +15465,7 @@ for ac_config_target in $ac_config_targets do case $ac_config_target in "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;; - "depdir") CONFIG_COMMANDS="$CONFIG_COMMANDS depdir" ;; "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;; - "gdbdepdir") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbdepdir" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; @@ -16038,7 +16023,6 @@ $as_echo "$as_me: executing $ac_file commands" >&6;} case $ac_file$ac_mode in "config.h":H) echo > stamp-h ;; - "depdir":C) $SHELL $ac_aux_dir/mkinstalldirs $DEPDIR ;; "default-1":C) for ac_file in $CONFIG_FILES; do # Support "outfile[:infile[:infile...]]" @@ -16140,11 +16124,6 @@ $as_echo "$as_me: executing $ac_file commands" >&6;} ;; esac done ;; - "gdbdepdir":C) - for subdir in ${CONFIG_SRC_SUBDIR} - do - $SHELL $ac_aux_dir/mkinstalldirs $subdir/$DEPDIR - done ;; esac done # for ac_tag diff --git a/gdbserver/configure.ac b/gdbserver/configure.ac index a549a8712fc1..f1466e8568d4 100644 --- a/gdbserver/configure.ac +++ b/gdbserver/configure.ac @@ -60,22 +60,11 @@ ACX_NONCANONICAL_TARGET ACX_NONCANONICAL_HOST # Dependency checking. -ZW_CREATE_DEPDIR +AM_SET_DEPDIR dnl Set up for gettext. ZW_GNU_GETTEXT_SISTER_DIR -# Create sub-directories for objects and dependencies. -CONFIG_SRC_SUBDIR="arch gdbsupport nat target" -AC_SUBST(CONFIG_SRC_SUBDIR) - -AC_CONFIG_COMMANDS([gdbdepdir],[ - for subdir in ${CONFIG_SRC_SUBDIR} - do - $SHELL $ac_aux_dir/mkinstalldirs $subdir/$DEPDIR - done], - [ac_aux_dir=$ac_aux_dir DEPDIR=$DEPDIR CONFIG_SRC_SUBDIR="$CONFIG_SRC_SUBDIR"]) - AC_CHECK_HEADERS([ \ arpa/inet.h \ fcntl.h \