From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: passt.top; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: passt.top; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=VdLXs/OL; dkim-atps=neutral Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by passt.top (Postfix) with ESMTPS id 12F0D5A0262 for ; Sat, 16 May 2026 17:46:03 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1778946362; 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: in-reply-to:in-reply-to:references:references; bh=RmjaddCAl8Svf0933uxQ6EdShFDR3jVVg30QYXS1W38=; b=VdLXs/OLy+IySssxML+uoF9K48CBkED5rdFre8mqRgltjRLmjDUrXpOTb7Vdf6nIhju77E uWSeLIIJuzlpe4mtsZSnvGvwPogScWRPRX2UyxSDvDadlHQv9PO/w+q1xqIfooHqGyXbmK 35eCQ85B/7NOxUhoU/jwu/sugZ4Br6Q= Received: from mail-wr1-f72.google.com (mail-wr1-f72.google.com [209.85.221.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-30-bJpBRxnkNquMa1QU6_1Hcg-1; Sat, 16 May 2026 11:46:01 -0400 X-MC-Unique: bJpBRxnkNquMa1QU6_1Hcg-1 X-Mimecast-MFC-AGG-ID: bJpBRxnkNquMa1QU6_1Hcg_1778946360 Received: by mail-wr1-f72.google.com with SMTP id ffacd0b85a97d-43d7b7bacddso465665f8f.0 for ; Sat, 16 May 2026 08:46:00 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778946360; x=1779551160; h=date:content-transfer-encoding:mime-version:organization:references :in-reply-to:message-id:subject:cc:to:from:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=RmjaddCAl8Svf0933uxQ6EdShFDR3jVVg30QYXS1W38=; b=jyC89RBfPqS8j7gzMw19uNpHlpMrYrw7KCqsT4Ytr8Oe+KIXzhoTffxdFXMXEkVdNx LljOQpeLHvataDSB1r4BLIE9B/Gwd+ltCgIKQgV2FE8hUw3c+Glx8G0P41kUxGbb0gK+ LG/llGuvkrn4muCwkwB8wnrCbqAbd8sDAUCKPoIzbKaw38y0BtkpTHJnZI+uTna/19oY vHOgk09ztLxFLy2jAA9hogfQmdAquZNBbxpJpZ7XjcKlik+Bkqga8zGSLeq7GOABauv/ 90pVY6drTYq7faE6GbCiLkPdIFdkMYqvqxjyspQlv8598CnOjLFeGMYcoMdAKpSvtZUd HRQw== X-Gm-Message-State: AOJu0Yy2L2khHV5G5/Pb0vZSxeagN7SkJujqYJds3ShfiEw0nG5/M/jX 1wcPTchi/BJw+LXscIuR5BDP+yrTrdwi4sCI4nWXuHiV+NuNi5e5lKGRO2vPDHHL+QYoEWj0v5B kfo+m1bEMcqS0hdQ4nrK+NS6fDEYAyhZcvBnGjpXlQ2xlyGsG8B9HWQBvpafevw== X-Gm-Gg: Acq92OHaePwQAVq26vHwO07/p+Wn3ZbLM4PrarqSAYJeYZkJeYfBpKK0WAjDXEIpre8 W0PbeGHFU1GVY2YLkw1fwalaXerUS9LBWTb5nz2WWFOm5FBGbCGHtC/BESBKCH+HuDpgucoJldS PTQoq/xDxTU81LLeFK09ekQ+SAWMVP56t2ZAT5+jfvszE5VjSFB2DptxNiBm+d1gvd6Dj7IGRxd sL0m7sH1xM58eVZagoSzNT17I8iGVzSCvhnQGi+NnlCNAdd7xCQUFDSNU0M2BBFIehQrHpORcRe eJBnB84/omxb6Sx1QOmlA2XPdJSHSz93xlzDUcLD5lQ2SJKa13nQtZoGcccL++/x4lnVCBJreVh IDfSeTesnz6USJxXxKzYmeOMnq86leaNafla+O+oW/YGAlBbJVA== X-Received: by 2002:a5d:5f45:0:b0:45d:4a00:b927 with SMTP id ffacd0b85a97d-45e5c5dd627mr12494270f8f.31.1778946359668; Sat, 16 May 2026 08:45:59 -0700 (PDT) X-Received: by 2002:a5d:5f45:0:b0:45d:4a00:b927 with SMTP id ffacd0b85a97d-45e5c5dd627mr12494222f8f.31.1778946359050; Sat, 16 May 2026 08:45:59 -0700 (PDT) Received: from maya.myfinge.rs (ifcgrfdd.trafficplex.cloud. [176.103.220.4]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-45d9e768c4fsm23390212f8f.8.2026.05.16.08.45.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 16 May 2026 08:45:58 -0700 (PDT) From: Stefano Brivio To: David Gibson Subject: Re: [PATCH v3 00/12] Improvements to static checker invocation Message-ID: <20260516174557.007a0d7b@elisabeth> In-Reply-To: <20260512055256.1800449-1-david@gibson.dropbear.id.au> References: <20260512055256.1800449-1-david@gibson.dropbear.id.au> Organization: Red Hat X-Mailer: Claws Mail 4.2.0 (GTK 3.24.49; x86_64-pc-linux-gnu) MIME-Version: 1.0 Date: Sat, 16 May 2026 17:45:58 +0200 (CEST) X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: WlFlb9FSipgz-qHorfn1aJEKC0FwZFRa6ZBNMVWdYjg_1778946360 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Message-ID-Hash: 2QACGF5PTQ6Z5IUEFYXVIY5EBHR4EJ2X X-Message-ID-Hash: 2QACGF5PTQ6Z5IUEFYXVIY5EBHR4EJ2X X-MailFrom: sbrivio@redhat.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: passt-dev@passt.top X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On Tue, 12 May 2026 15:52:44 +1000 David Gibson wrote: > While working on pesto, I ran into a number of awkward errors with the > static checkers. This series reworks the invocation of the checkers > in a way that will let us deal with that. As a bonus, it also gives > us static checking for passt-repair. It also a number of other > cleanups to the Makefile that seemed natural along the way. > > v3: > - Rework changes to $(FLAGS) so they're much less likely to have > side effects we're not ready for. > v2: > - Fixed nasty test failure in test/build/build.py Tested with current packaging rules / build scripts on Alpine, Debian, Fedora, openSUSE, and applied (dropping extra whitespace in 4/12 as noted). I think it would be nice, as a follow-up, to drop the comments that 4/12 introduced: +# Mandatory preprocessor flags that won't be overridden with $(CFLAGS) +# FIXME: Could some of these be default, rather than required? (same for CPPFLAGS), because, as we discussed, those are all default, can actually be overridden as distribution packages already do (so this is misleading for distribution maintainers), and I don't see a particular value in distinguishing what flags *could* be perhaps dropped to have something strictly building. They are all useful for a reason or another. But I didn't touch those, I didn't feel like sneaking in a substantial change like that and I didn't want to delay this series further, either. I had a quick look at package recipes of Chimera, PLD, and Void Linux, I didn't test things there but I don't see any way this series could cause issues there. Somewhat interestingly, I came across many different ways to override flags, taking -D_FORTIFY_SOURCE as example: - Alpine doesn't override / set it at all, the test in our Makefile doesn't set it there, either. Notably, this test was added in commit 38363964fc96 ("Makefile: Enable _FORTIFY_SOURCE iff needed"), specifically for Gentoo - Debian and Void Linux append -D_FORTIFY_SOURCE=2, that is, they duplicate our flag, in CFLAGS - Fedora (with my spec file, where I didn't set any %_fortify_level) overrides it with -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 in CFLAGS - openSUSE used to append -D_FORTIFY_SOURCE=3 (similar to Debian and Void Linux), but now uses -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=3 - PLD Linux appends -Wp,-D_FORTIFY_SOURCE=2 I found a rather impressive summary here: https://www.anthes.is/nix-internals-cflags.html -- Stefano