From nobody Mon Jun 10 16:53:01 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4VydCg53ggz5MFZh for ; Mon, 10 Jun 2024 16:53:03 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VydCg4br8z4vcH; Mon, 10 Jun 2024 16:53:03 +0000 (UTC) (envelope-from jhb@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1718038383; 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=nskcfSZLKFqPtNSCHb+tHVDhAzTvWuXgXULd/1t8wE4=; b=KLLmg6uZKbWH9U/73loL78qd39dM7mIVDo1lN27PJwoAf455oYRIkwbPigYwZ5o2pYZ4yX nXuDI4vdB5MrzTDuuxsiN9IEhcExFNPwziu4kAlSFxqNrxmx9X6iyzxBMdJygC2dS2j5jK 6kHWRrplRMZTejNeiDZrYqy9g30Vl7BinxXVeIF1yetEU8pGa7VOjI6XJ5hEwN33/L4M/9 XrpWtO4E4JTAH7TKvcys9aeoDo89TRLPE7fc/krQ0aOvl8wSPPzzI4+oaZtNSuvnwYZiXD npKtCZhNi8IwJRWwK2WLVqiolWc8YydtsRz6eX6BdWk3M2t2dJHOmbPr08I8HA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1718038383; a=rsa-sha256; cv=none; b=oTYt1irKTd1l7KBHXbKecLYRMegSFmKkcegK3VE1vAh6Z3uNu9z20bknhFmDQCN61mR/15 pfwYR6qDD04eRzOktvOvgEC3rF8Er+JTR31E0whk2baqSh206EIDjtnXcf8vNkXiyBOx+O mXct1PcsBj3aK9zG9so0YMOXeYWdL3BoO3IYsU9z1bQV0ut00zZ/SovQyyXUq2NL7AXtgv VWm2p8lPbKBxGtgzAytPnkFLA43a7XJMDJqkGQJog4rDX7abZ3Z1c8JyueGMq4QsKDRjP8 O6WG64bYeaJirokfyq/eQ9y8dQFBHovXPam0JTWggjkoAEoKoCxzHrSNq2CkfQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1718038383; 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=nskcfSZLKFqPtNSCHb+tHVDhAzTvWuXgXULd/1t8wE4=; b=ltMd5qobGR+bRhBNEq2j3VdLufYsHpymuiY/tjoDUQ34F2MdkrbKM0zck0XAKSp+RXxMJr 0sI98FERYUeulUAd68k6kdA6jGeVJCmX1hdgfWzgz1/K0PO/t9VT6sACt7E70+edMEAzzs +2Cp3GcB/l0lWGeJuu1moreTfYWa1L4ZB/+O3kFg/NHNWQx1J/eTPbJod08jcsMw9hMoXD fyxfDb/2YFYBLeHJ0oR+w1oqmL8PdCQW1t81FUdey6kPD4CjKxLdrgafvIAvg43WE9JWqy YL87dlyfn+7SM0j7GPApO/dDWpFhJjflNAmJvbQgHPt9jG68Om0uPwIxLZxblg== Received: from [IPV6:2601:644:937f:4c50:ddd0:3ab8:e148:d3c9] (unknown [IPv6:2601:644:937f:4c50:ddd0:3ab8:e148:d3c9]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: jhb) by smtp.freebsd.org (Postfix) with ESMTPSA id 4VydCf6z7pz1DRG; Mon, 10 Jun 2024 16:53:02 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Message-ID: <3678a53a-4871-426d-9c4b-e0d145353b82@FreeBSD.org> Date: Mon, 10 Jun 2024 09:53:01 -0700 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: generated sources Was: git: 408957613bc0 - main - Regen Content-Language: en-US To: Brooks Davis , Gleb Smirnoff Cc: Dmitry Salychev , Lexi Winter , Mariusz Zaborski , dev-commits-src-all@freebsd.org References: <3edabe3b-4b51-401f-ad64-e36c84fd455b@FreeBSD.org> From: John Baldwin In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 5/23/24 2:37 PM, Brooks Davis wrote: > On Thu, May 23, 2024 at 11:20:08AM -0700, Gleb Smirnoff wrote: >> Hi, >> >> sorry for slightly diverting the discussion, but looks like this thread is the >> right place... >> >> On Wed, May 22, 2024 at 12:55:24PM -0700, John Baldwin wrote: >> J> I don't think it's worth reverting at this point. For `make sysent` I would >> J> suggest 'sysent: Regen' as a commit log in the future. We typically use >> J> 'src.conf.5: Regen' after running `make makeman`. >> >> On Wed, May 22, 2024 at 05:05:14PM +0000, Brooks Davis wrote: >> B> This is more or less standard practice for generated files. These >> B> commits are of basically no interest. Historically they had to exist >> B> because the source file $FreeBSD$ entries were embedded in the generated >> B> files and thus had to be final. That isn't true any more so I often just >> B> include them in the origional commit unless I'm doing a lot of minor >> B> changes to the source files. >> >> Is it possible to generate the files during normal kernel build? That would >> require lua packages installed, but we already almost require git installed to >> work with FreeBSD sources. Absence of lua can be checked in Makefile and a >> verbose error message would be printed. Or may be we can use the small lua that >> we have in the loader? Sorry if the very last suggestion was stupid - really >> don't have any knowledge in the area. > > TL;DR: No one likes the current state of affairs, but it's complicated > to fix or we'd have done it long ago. > > We'd like to generate these files at build time, but at least > sys/sys/syscall.mk is difficult to handle as it's required to build libc > so I belive we'd need to arrange to create it before entering lib/libc. > The others seem straightforward, but right now we've got a single script > to generate everything and we'd want to be selective about generating > things so we did it in the right place. I know there's some work in > progress to turn sys/tools/makesyscalls.lua into something more > library-like, but it's not done. (I've not been helping by adding > things to makesyscalls.lua and thus moving the goalposts...) > >> After the xz/liblzma backdoor all the generated code committed manually makes >> me concerned, as it has 0% chance to get reviewed by community. > > This is a valid, but not very practical concern. We check that these > are in sync routinely in github CI and could easily factor those checks > out to do in jenkins if we wanted more immediate post-commit feedback. Also, FWIW, the discussion I've seen on some other lists (e.g. for GDB/binutils) is actually favoring checking in auto-generated files like configure since it's easier to validate what files are used to generate a release tarball as a counter to the xz case where one of the issues is that the release tarball was justn't a straight tarball of a git tag which gave an opportunity for the actor to inject other changes into the release tarball. -- John Baldwin