From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from eggs.gnu.org (eggs.gnu.org [IPv6:2001:470:142:3::10]) by sourceware.org (Postfix) with ESMTPS id 3C7323858D1E for ; Sun, 12 Feb 2023 18:44:42 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 3C7323858D1E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gnu.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gnu.org Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pRHL7-000548-Px; Sun, 12 Feb 2023 13:44:41 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=In-Reply-To:MIME-Version:References:Subject:To:From: Date; bh=T3MIFn3eZYzCZUncoGn1z8Okui9QMwCH9cJzyVkPMT0=; b=VXphPmLEzS5GN0jAb8k3 i4uPonqdg/NlGT4nWgdxGIeig1nT++NmwuUcni/Mu8fh9uqHuEL8YC0QC/VKWFAaf5e9680rbcuMp 0Lbv6Tr/p7FZq39vIUo2e8jUHnzgnLv/lpLnrFdW7dFNPzlcYqShprV/gKXv9igfYBp4Mt33jThr9 YSk3ql10NF1xvs7qQ+VEo+pUrOIIQyq32RB9lEi9XOFMQmCVw5wlIy6oYNzw8gy9Vj82sazJP6YXh MUS+DuKueuKKignkAMeJIdp4lAGaE+MkkKnrudYy2G55NzK7zzXNz4N69NOdV2YG+Qr0NS/aq1i0X S8ZghPU1Vntuvg==; Received: from lfbn-bor-1-1163-184.w92-158.abo.wanadoo.fr ([92.158.138.184] helo=begin) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pRHL7-0000IF-Iw; Sun, 12 Feb 2023 13:44:41 -0500 Received: from samy by begin with local (Exim 4.96) (envelope-from ) id 1pRHL5-005bD0-19; Sun, 12 Feb 2023 19:44:39 +0100 Date: Sun, 12 Feb 2023 19:44:39 +0100 From: Samuel Thibault To: Sergey Bugaev Cc: bug-hurd@gnu.org, libc-alpha@sourceware.org, =?utf-8?Q?Fl=C3=A1vio?= Cruz Subject: Re: [RFC PATCH mig 7/12] Drop -undef -ansi from cpp flags Message-ID: <20230212184439.y3lpv2fy7korek3l@begin> Mail-Followup-To: Sergey Bugaev , bug-hurd@gnu.org, libc-alpha@sourceware.org, =?utf-8?Q?Fl=C3=A1vio?= Cruz References: <20230212111044.610942-1-bugaevc@gmail.com> <20230212111044.610942-8-bugaevc@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20230212111044.610942-8-bugaevc@gmail.com> Organization: I am not organized User-Agent: NeoMutt/20170609 (1.8.3) X-Spam-Status: No, score=-11.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Applied, thanks! Sergey Bugaev, le dim. 12 févr. 2023 14:10:38 +0300, a ecrit: > Since GNU Mach commit d30481122a5d24ad6b921062f93b9172ef922fc3, > i386/machine_types.defs defines types based on defined(__x86_64__). > Supressing the built-in macro definitions will now result in the wrong > type being silently selected. > > -undef was initially introduced in commit > 78b6a7665db7b2eae367e17102821cbdca231d19 without much of an explanation. > -ansi was introduced in commit 6940fb91859e46b2e96a331a029f2dc2a0ee51c9 > "to avoid -Di386=1 and the like". > > Since glibc has been using MIG with CPP set to a custom GCC invocation > which did *not* use either flag, it appears that everything works well > enough even without them. On the other hand, not having __x86_64__ > defined most definetely causes issues for anything that does not set a > custom CPP when invoking MIG (i.e., most users). Other built-in > definitions could be used in the future in a similar way (e.g. on other > architectures); it's really more of a coincidence that they have not > been used until now, and things kept working with -undef. > --- > mig.in | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/mig.in b/mig.in > index 63e0269..94fd500 100644 > --- a/mig.in > +++ b/mig.in > @@ -38,7 +38,7 @@ migcom=${MIGDIR-$libexecdir}/${MIGCOM-@MIGCOM@} > # The expansion of TARGET_CC might refer to ${CC}, so make sure it is defined. > default_cc="@CC@" > CC="${CC-${default_cc}}" > -default_cpp="@TARGET_CC@ -E -x c -undef -ansi" > +default_cpp="@TARGET_CC@ -E -x c" > cpp="${CPP-${default_cpp}}" > > cppflags= > -- > 2.39.1 > > -- Samuel --- Pour une évaluation indépendante, transparente et rigoureuse ! Je soutiens la Commission d'Évaluation de l'Inria.