From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id 9IHZBEWjkmdKzxgAWB0awg (envelope-from ) for ; Thu, 23 Jan 2025 15:15:01 -0500 Authentication-Results: simark.ca; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=cx/B0iVm; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id 04DFA1E100; Thu, 23 Jan 2025 15:15:01 -0500 (EST) X-Spam-Checker-Version: SpamAssassin 4.0.0 (2022-12-13) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-7.4 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H2 autolearn=ham autolearn_force=no version=4.0.0 Received: from server2.sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id CE33F1E05C for ; Thu, 23 Jan 2025 15:14:59 -0500 (EST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 6724F3858D33 for ; Thu, 23 Jan 2025 20:14:59 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6724F3858D33 Authentication-Results: sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=cx/B0iVm Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTP id F21263858405 for ; Thu, 23 Jan 2025 20:14:21 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org F21263858405 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org F21263858405 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.129.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1737663262; cv=none; b=aU6Rjb13Y4tMf9kKIxeTQ6Bt9oH0PCaaSteXsX0sDGVtGKCAuf6PO5g/pQzs6bCFbUMzoOtuKvY84KiOtxb9XN+xSNWk/Sc/v+bRTK8QLwofAC6tkt0+sUn3hz4hWZ/bV0uzXKWQSLGswaDiaTLnxT6v28+s+8LJ6dYcH/k6ImE= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1737663262; c=relaxed/simple; bh=4eZ48VgsHXxZJIeM+stA+7xwne1nIJUEYsDKKetp4ls=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=bwvKUv5E6YQpTgV6/iAwX0KEoz2JG5tyoASQry49PBN7czqzStxB6QX9M0bu5Xbq1pjUeZjDMwsWBTYjOjKFJZRHrvoxQ0Mf8GK5hmdgsttOywBQ9T2mgNEMkdUveKp5BAtLLXNfoZcGCfbDyxweOWfk+Rj59mc2yVshiZsoENI= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org F21263858405 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1737663261; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=HorXCFr4Oscnh3ubSgBZVcGwazdgZDlawXo1nkuuHl8=; b=cx/B0iVmYMwfiPqq8PkKybKltLF30IjU5Z/3Z+xRcTYv7eoMYQGk3Agp1CBl1MSuQATmaF iwxQkWwhg2UAfm75ocSKw6evN9cYrc3Kouk+dl1wCchQHnPeL2Pq++Y9nuaJ1xn4Vz+q0d d/SqcC9nzuTtRvcf8DG/bmIoEuHAGNQ= Received: from mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-411-1B9p0zsnMmGhZ6BE-Z8jyg-1; Thu, 23 Jan 2025 15:14:20 -0500 X-MC-Unique: 1B9p0zsnMmGhZ6BE-Z8jyg-1 X-Mimecast-MFC-AGG-ID: 1B9p0zsnMmGhZ6BE-Z8jyg Received: from mx-prod-int-04.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-04.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.40]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id A135819560BB for ; Thu, 23 Jan 2025 20:14:19 +0000 (UTC) Received: from fedora.redhat.com (unknown [10.96.134.84]) by mx-prod-int-04.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 1186819560AD; Thu, 23 Jan 2025 20:14:17 +0000 (UTC) From: Guinevere Larsen To: gdb-patches@sourceware.org Cc: Guinevere Larsen Subject: [PATCH] gdb/configure: fail configure if all targets requested with 32bit bfd Date: Thu, 23 Jan 2025 17:13:39 -0300 Message-ID: <20250123201338.158819-2-guinevere@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.40 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: Ul6tWwYRqlST3TBn2jkcSVq1cT2BMW3Z5QtDEIH0KeM_1737663259 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit content-type: text/plain; charset="US-ASCII"; x-default=true 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~public-inbox=simark.ca@sourceware.org As PR sim/28684 explains, it isn't possible to compile GDB with all targets enabled and not enabling 64 bit bfd. In 64 bit hosts, 64 bit bfd is forced, so the build works, but in 32 bit hosts, that has to be explicitly enabled. I ran into this when I tried compiling GDB on a mips64 machine running a 32 bit OS. Along with the errors in the PR, several other architectures are also required, notably aarch64 and other explicitly 64bit targets. Additionally, some 32 bit files required for the gdb mips target aren't added to the makefile. Considering the last comment in the bug says this isn't going to be fixed on the binutils side, I didn't think it was worth trying to fix the GDB side. Instead, this commit causes the configure script to fail if all targets were requested and 64 bit bfd isn't enabled. If that is ever fixed, we can revert this commit. I considered adding this to the top level configure script, but couldn't figure out how to detect the situation in there, so this was my next best idea. Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=28684 --- gdb/configure | 4 +++- gdb/configure.ac | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/gdb/configure b/gdb/configure index 1531f62f76a..cfb4f446ef8 100755 --- a/gdb/configure +++ b/gdb/configure @@ -25005,7 +25005,9 @@ if test x${all_targets} = xtrue; then if test x${enable_64_bit_bfd} = xyes; then TARGET_OBS='$(ALL_TARGET_OBS) $(ALL_64_TARGET_OBS)' else - TARGET_OBS='$(ALL_TARGET_OBS)' + # If all targets were requested, but 64 bit bfd is not enabled, + # the build will fail. See PR 28684. + as_fn_error $? "--enable-targets=all requires --enable-64-bit-bfd" "$LINENO" 5 fi fi diff --git a/gdb/configure.ac b/gdb/configure.ac index e9312b1bc64..77f774e23ee 100644 --- a/gdb/configure.ac +++ b/gdb/configure.ac @@ -257,7 +257,9 @@ if test x${all_targets} = xtrue; then if test x${enable_64_bit_bfd} = xyes; then TARGET_OBS='$(ALL_TARGET_OBS) $(ALL_64_TARGET_OBS)' else - TARGET_OBS='$(ALL_TARGET_OBS)' + # If all targets were requested, but 64 bit bfd is not enabled, + # the build will fail. See PR 28684. + AC_MSG_ERROR([--enable-targets=all requires --enable-64-bit-bfd]) fi fi -- 2.48.1