From patchwork Sat Feb 8 16:21:12 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Maciej W. Rozycki" X-Patchwork-Id: 37769 Received: (qmail 64434 invoked by alias); 8 Feb 2020 16:21:31 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 64404 invoked by uid 89); 8 Feb 2020 16:21:30 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-8.4 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_2, GIT_PATCH_3, KAM_ASCII_DIVIDERS autolearn=ham version=3.3.1 spammy=Canadian, canadian, crossed, HX-Envelope-From:prvs X-HELO: esa5.hgst.iphmx.com Received: from esa5.hgst.iphmx.com (HELO esa5.hgst.iphmx.com) (216.71.153.144) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sat, 08 Feb 2020 16:21:20 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1581178881; x=1612714881; h=date:from:to:cc:subject:message-id:mime-version; bh=x2Y2BeUOdls+7vvSxzQVi4I8PF2YkUBv7wgE6m77b20=; b=AdRhwPusjyVxWwXXPhgEqS5lSn0x85Z2Ht6+Jr9sfPre8wqT8gliPAdz XAqTjVn1vfQ/oTKFhCo9FR9PRXsjDOxU60aHoLXJkwpCmVB+gO5mGaNi1 pfopCLfFsFMhUZg46hTRlGW78EnZGE9TC4UTgpSaKQfrSIWRuQI1OIigh aMraneiSFjUSr03FxINLhLzyrtf/8elRCOk2NQnxilsA1olInVV3EcRog /SeXVsOWPyeNVTiQ1BT9EnunexV8bQ3cuTDRwlAl5ZrvSAMLkfQKxlCvV 6t6cjBhgY+lTNejkvN1jzDKjD2Hot+w5pVU8HpErmZ6Sb18IvI8TvGpqE g==; IronPort-SDR: wrFxyhjehpL6g5do4OimB6mYP7ke19L9YlawjsFeEDGBPH2KmgTN9Wjumb/FnRzDggkmdLTwK5 mTUR9WFILmrmCCsS1rA/aX5TFF3QIsfInZB9ai/HWqDBpP0UvFpwgb54h43LGCZraudIMaJTCQ srVIDMTf2zHQbT8CTPqJZX2Upf5+gu0wJWT9XNa6nj3gVfNDW83680e98fjfazE8n0g7ypobLx 6eYkc0sQ3mzci7VrtepfJ5DbPHb/8NcqY3Klv8O8y+RRTfCwcsNdpWo2iDN9WJj2PbRfOemjfB JS8= Received: from uls-op-cesaip01.wdc.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 09 Feb 2020 00:21:19 +0800 IronPort-SDR: rfVgMtP0irqt5zndzVKGsp3hX76az1AGLbx8s1bP6m8EA2yHzA24PSvYjHajAGTJRF8v1JjYOJ Wdt83fw7XZmeqk7vcJHHaPhcwSISoq2eS8BIpSBBcH3E7CM+Rt5xQ85rN0HiFgQNDlnviz/A/C 1MWD75d4kBvM9KN/7nTAq0cb9ztisSLqpjy42fjc3gVoUwtX7Duy+B1nPb+jG3Wog+CaROihra 3dxA2BmSaT4yvS21Lu717E6Ma97S7K2TgXuG3fQOdSlXden3wpqJOIvPFyNFZA36cP5cnFijgn rhkDN8Bo75tsFtrg2XAUtAPd Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep01.wdc.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 08 Feb 2020 08:14:14 -0800 IronPort-SDR: ExyP020YsChlrVeABqL92bpSCpdaw+o5xoxfc+orAZTCdNTxlbKJp9c4Mf4IXomFE/l9ATk02H o908yqsQ/jygOLNbgeVjfrSEcjGO8qpNbecjt45i0Llj9G0LVuUbq3RFAKxPdwptIvovTufKR0 15lv7+YiYq2jvHsCzm/CuKzIIC72lAB7DvI1vdOMHajQy8tir7lcRrI0rVzyHOLtYoovmLIUxU O8muWKXvbQ15fhxXhAiZHv/ex/6EoZtFfWKqAtl026GXKg8K3AUUjk17/t9wx+IXhWukXpliHi CQE= WDCIronportException: Internal Received: from unknown (HELO redsun52) ([10.149.66.28]) by uls-op-cesaip02.wdc.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 08 Feb 2020 08:21:17 -0800 Date: Sat, 8 Feb 2020 16:21:12 +0000 (GMT) From: "Maciej W. Rozycki" To: gcc-patches@gcc.gnu.org cc: Tom Tromey , gdb-patches@sourceware.org, binutils@sourceware.org Subject: [PATCH] configure: Re-disable building cross-gdbserver Message-ID: User-Agent: Alpine 2.21 (LFD 202 2017-01-01) MIME-Version: 1.0 Correct fallout from commit 919adfe84092 ("Move gdbserver to top level") and revert to not building `gdbserver' in a cross-configuration, that is where host != target, matching the documented behaviour. We have no way to support non-native `gdbserver', and native `gdbserver' is usually of no use with cross-GDB of the chosen host. * configure.ac: Do not build `gdbserver' if $is_cross_compiler. * configure: Regenerate. --- Hi, Verified with a native build, a crossed build of a native configuration and a build of a cross-debugger; Canadian Cross not checked. OK to apply? NB I have noticed that the gdbserver(1) man page is still being built and installed (as ${target_alias}-gdbserver.1, if building a cross-debugger), even if `gdbserver' itself is not (and it is not built if only `gdbserver' is while GDB is not). Obviously this is due to the man page still living under gdb/doc/, and I presume it will be addressed sometime soon, by moving the man page somewhere under gdbserver/, right? Also there are currently a number of mismatches in configure.ac between the gcc and the binutils-gdb repositories; what is the plan to eliminate them? Maciej --- configure | 5 +++-- configure.ac | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) gdbserver-no-cross.diff Index: binutils-gdb/configure =================================================================== --- binutils-gdb.orig/configure +++ binutils-gdb/configure @@ -3538,12 +3538,13 @@ case "${target}" in ;; esac -# Only allow gdbserver on some systems. +# Only allow native gdbserver and then only on some systems. if test -d ${srcdir}/gdbserver; then if test x$enable_gdbserver = x; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gdbserver support" >&5 $as_echo_n "checking for gdbserver support... " >&6; } - if (srcdir=${srcdir}/gdbserver; \ + if test x${is_cross_compiler} = xyes \ + || (srcdir=${srcdir}/gdbserver; \ . ${srcdir}/configure.srv; \ test -n "$UNSUPPORTED") then Index: binutils-gdb/configure.ac =================================================================== --- binutils-gdb.orig/configure.ac +++ binutils-gdb/configure.ac @@ -782,11 +782,12 @@ case "${target}" in ;; esac -# Only allow gdbserver on some systems. +# Only allow native gdbserver and then only on some systems. if test -d ${srcdir}/gdbserver; then if test x$enable_gdbserver = x; then AC_MSG_CHECKING([for gdbserver support]) - if (srcdir=${srcdir}/gdbserver; \ + if test x${is_cross_compiler} = xyes \ + || (srcdir=${srcdir}/gdbserver; \ . ${srcdir}/configure.srv; \ test -n "$UNSUPPORTED") then