From patchwork Tue Apr 18 09:39:29 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jakub Jelinek X-Patchwork-Id: 84714 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp2712437vqo; Tue, 18 Apr 2023 02:40:20 -0700 (PDT) X-Google-Smtp-Source: AKy350ZYEUEgTfOYkVcpdq0t4S/2RpChhoJJeZqB0smgqnEw8WBpBt09uH4DsK6PVA4CvbT7eRKE X-Received: by 2002:a50:fb9a:0:b0:506:a7a4:88a9 with SMTP id e26-20020a50fb9a000000b00506a7a488a9mr1910548edq.4.1681810820685; Tue, 18 Apr 2023 02:40:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681810820; cv=none; d=google.com; s=arc-20160816; b=WIgcNj9WzNzgT09MkIrcx3+l4Es3en7jazTc+CnuVeMmU5BNXGq1ClakS/XBL3TIYQ sbP08wdjQXUl9hsGFDm0ZwnGjbxv8tyjvv9E58Hfz9wBe5+XSqabP8XdKRdJ1agV9SUy dZEnegslEcuKQel2Z5ythoOno5nvcCZIkCjlfTGFnqiLVcHCknnn0a6dqUhx3KEFpDbr QH/HsM+0ZzzXuS9xjKJlbt5zFv/tK88wO/TGu2sDHpfHgq8D0PNRRrFqjeyqd6IzdkkE h8zq5r25mAkcKio1u3pCqZkbC3YwQ3GbuXLtsPSjtNgqlCuAPas/U9I58qn7NBN9dX5k eacw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:reply-to:from:list-subscribe:list-help:list-post :list-archive:list-unsubscribe:list-id:precedence :content-disposition:mime-version:message-id:subject:cc:to:date :dmarc-filter:delivered-to:dkim-signature:dkim-filter; bh=AdIH6XVNrvQvMWgEco7gWBkcyBZ+z3mSygAp44nsxhA=; b=hkQNDJMij3bifsLS9jOqLA7NFgN9WMlqR0o89vFf3m3wB03bCiu4/2Q4van+dWxLhB s6LS53oFanrblsoqrqNUT3Mu59C0unxZ+HAOiWjgtxFwlviLSMn5FFc0bZIzq3JMfozR bRlwfGjuzOUw9/jrKFneL5tbY4Su2YRikzFZXXJpZZW20dFx/G3xQ4kJi+26wEcazuuR dA9L0sc+f8ym83/AptEtSZjDiP75qIpCxfMsy52oBBqOObmp6b79qZNBe39XF9ql0dva B2VAcHmCAKI0ovYWcf8YiK889IVWfgejv/uoeRNvgyfkG1s4r3Pyonl5Evcct7iPsxtP xWFQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=POT102UU; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from sourceware.org (ip-8-43-85-97.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id h4-20020a50ed84000000b005067ce9bf36si9465549edr.420.2023.04.18.02.40.20 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 18 Apr 2023 02:40:20 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=POT102UU; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 97D6E3858414 for ; Tue, 18 Apr 2023 09:40:19 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 97D6E3858414 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1681810819; bh=AdIH6XVNrvQvMWgEco7gWBkcyBZ+z3mSygAp44nsxhA=; h=Date:To:Cc:Subject:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe:From:Reply-To:From; b=POT102UUTNGqvOCkk/w005EfWJj1oTf2q5RUHhAb5S0dnpGjX22I/uqKh8FmDm05o DOMNPJDtjV47ANKuRaBxDyo3P/EmbRr1Ip2PFsW31+2lHRh6lV5lYUzRAVPBQ6iGDK ZGsQMebA5ZNK2MPRY91OrrR6I8FTIFa/A047S29k= X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id 3EE833858D1E for ; Tue, 18 Apr 2023 09:39:36 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 3EE833858D1E Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-224-fIbBk9irPrqc05vVeaZEHg-1; Tue, 18 Apr 2023 05:39:34 -0400 X-MC-Unique: fIbBk9irPrqc05vVeaZEHg-1 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 5DC41886063; Tue, 18 Apr 2023 09:39:34 +0000 (UTC) Received: from tucnak.zalov.cz (unknown [10.39.194.25]) by smtp.corp.redhat.com (Postfix) with ESMTPS id F3AFD728FD; Tue, 18 Apr 2023 09:39:33 +0000 (UTC) Received: from tucnak.zalov.cz (localhost [127.0.0.1]) by tucnak.zalov.cz (8.17.1/8.17.1) with ESMTPS id 33I9dUNp111844 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Tue, 18 Apr 2023 11:39:31 +0200 Received: (from jakub@localhost) by tucnak.zalov.cz (8.17.1/8.17.1/Submit) id 33I9dTwi111843; Tue, 18 Apr 2023 11:39:29 +0200 Date: Tue, 18 Apr 2023 11:39:29 +0200 To: Arthur Cohen , Richard Biener Cc: gcc-patches@gcc.gnu.org, Thomas Schwinge Subject: [PATCH] rust: Disable --enable-languages=rust and silently exclude it from --enable-languages=all for GCC 13 Message-ID: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.5 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Disposition: inline X-Spam-Status: No, score=-3.1 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, KAM_NUMSUBJECT, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Jakub Jelinek via Gcc-patches From: Jakub Jelinek Reply-To: Jakub Jelinek Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org Sender: "Gcc-patches" X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1763506463405505530?= X-GMAIL-MSGID: =?utf-8?q?1763506463405505530?= Hi! As discussed on IRC, gccrs can't compile the standard libraries yet and requires annoying -frust-incomplete-and-experimental-compiler-do-not-use option to compile anything. As such it is better to disable this at least for GCC 13.1, we'd keep it allowed on the trunk where hopefully support to compile at least some standard libraries will land soon and eventually a borrow checker. If enough Rust support is backported from trunk to 13 branch before 13.2, we could revert this change then. Tested on x86_64-linux with --enable-languages=c,c++,rust and --enable-languages=c,c++,all , ok for 13 branch? 2023-04-18 Jakub Jelinek * configure.ac: For --enable-languages= mentioning explicitly rust emit an error, if included in all etc., silently disable rust. * configure: Regenerated. Jakub --- configure.ac.jj1 2023-04-17 13:47:26.527792492 +0200 +++ configure.ac 2023-04-18 11:22:10.893011557 +0200 @@ -2150,6 +2150,18 @@ if test -d ${srcdir}/gcc; then ;; esac + # Disable Rust for GCC 13 release. + case ${add_this_lang}:${language} in + yes:rust) + # Specifically requested language; tell them. + AC_MSG_ERROR([Rust is not supported in GCC 13 release]) + ;; + *:rust) + # Silently disable. + add_this_lang=unsupported + ;; + esac + # Disable jit if -enable-host-shared not specified # but not if building for Mingw. All code in Windows # is position independent code (PIC). --- configure.jj1 2023-04-17 13:47:26.519792608 +0200 +++ configure 2023-04-18 11:22:33.500683809 +0200 @@ -8909,6 +8909,18 @@ $as_echo "$as_me: WARNING: GDC is requir ;; esac + # Disable Rust for GCC 13 release. + case ${add_this_lang}:${language} in + yes:rust) + # Specifically requested language; tell them. + as_fn_error $? "Rust is not supported in GCC 13 release" "$LINENO" 5 + ;; + *:rust) + # Silently disable. + add_this_lang=unsupported + ;; + esac + # Disable jit if -enable-host-shared not specified # but not if building for Mingw. All code in Windows # is position independent code (PIC).