Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rV5Zo-00Emm2-9k for pgsql-hackers@arkaria.postgresql.org; Wed, 31 Jan 2024 08:04:09 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1rV5Zn-00CQ6Q-9v for pgsql-hackers@arkaria.postgresql.org; Wed, 31 Jan 2024 08:04:07 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rV5Zl-00CQ6I-9S for pgsql-hackers@lists.postgresql.org; Wed, 31 Jan 2024 08:04:06 +0000 Received: from out1-smtp.messagingengine.com ([66.111.4.25]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rV5Ze-004I7r-A4 for pgsql-hackers@postgresql.org; Wed, 31 Jan 2024 08:04:04 +0000 Received: from compute7.internal (compute7.nyi.internal [10.202.2.48]) by mailout.nyi.internal (Postfix) with ESMTP id BEED15C0061; Wed, 31 Jan 2024 03:03:56 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute7.internal (MEProxy); Wed, 31 Jan 2024 03:03:56 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eisentraut.org; h=cc:cc:content-transfer-encoding:content-type:content-type :date:date:from:from:in-reply-to:in-reply-to:message-id :mime-version:references:reply-to:subject:subject:to:to; s=fm2; t=1706688236; x=1706774636; bh=hx4iCz6CoQrSQsJkWHPHX6M9Zp8ZHLrP G/o6vCHyxeA=; b=k1ZtTMbOqQndb7WtnM2jBwabPBcoEB7ejkY8c4YVyyWxwGuc xN2Bvl2HMEsRNKHo/IFjlZQ/aAEau/2aFccbAkapWYmeflPuoUVTGMuOeFv8fO0A anLJ8zx1oYfLZdZjVDfb1iJ7hBbi4K4NEc15IBdChYjlXChd0srIsySS/OHJdgmJ MorHXI835xb+mXicm0Syn9xqJuKQATcqNgeTr58IUtLOwylfDiwV8lCVbdzgX8hk ycHo0QOUtO9f8VHt8K3YwPmRtqu3BNDJ1quiCy70e+2mvMm59JIcDblDOx1Hb8df VHD7K+tpyWdWPPgGgNoQmkjgfH//uVz4rXlI2g== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1706688236; x= 1706774636; bh=hx4iCz6CoQrSQsJkWHPHX6M9Zp8ZHLrPG/o6vCHyxeA=; b=L pu/twsMr1bgdzRUSYVd+di7wrCZHTKI5+qOFhfAddrHWe+gDf4cL5QkMsaXTVXC0 rlxXVes7VYTyBWCpHH0svJV4LYCyER+iicVOOZitAjOVNVQTiMoqdN+S0LCFV8eM TElYxtKAB8LhzpbbqITD+w9nqhWfEmhuOWx9dkt0I8Q1gAqRvd983Eho6gUxfTf9 60rVfOYQ1k9H5kCjecaumeacaB/bkIiK5lUBCZd0XrYvhxOrge1dZaJCsOiu50un q1kD2bvR2d4jxLa4uraEMw48v/DcYcVzcugRbSM7cVAnkpni+Cj7dpvwmlovFzJw NFRt+cL0m/aZFQ11cGAmw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvkedrfedtkedguddufecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpefkffggfgfuvfevfhfhjggtgfesthekredttddvjeenucfhrhhomheprfgv thgvrhcugfhishgvnhhtrhgruhhtuceophgvthgvrhesvghishgvnhhtrhgruhhtrdhorh hgqeenucggtffrrghtthgvrhhnpeejhfevhedttefgfffhhfeffefggffhffelgfeiueeu keehvdehvdefheffvdefueenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmh grihhlfhhrohhmpehpvghtvghrsegvihhsvghnthhrrghuthdrohhrgh X-ME-Proxy: Feedback-ID: ie0a040ee:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Wed, 31 Jan 2024 03:03:55 -0500 (EST) Message-ID: Date: Wed, 31 Jan 2024 09:03:55 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: make dist using git archive Content-Language: en-US To: Eli Schwartz , Tristan Partin Cc: pgsql-hackers References: <40e80f77-a294-4f29-a16f-e21bc7bc75fc@eisentraut.org> <02714192-6eba-4145-ac1c-0a245801014f@eisentraut.org> <76516f81-31b0-40db-b30e-2fe9e332895a@gmail.com> From: Peter Eisentraut In-Reply-To: <76516f81-31b0-40db-b30e-2fe9e332895a@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 26.01.24 22:18, Eli Schwartz wrote: > Hello, meson developer here. Hello, and thanks for popping in! >> 3. Meson does not support tar.bz2 archives. > > Simple enough to add, but I'm a bit surprised as usually people seem to > want either gzip for portability or xz for efficient compression. We may very well end up updating our requirements here before too long, so I wouldn't bother with this on the meson side. Last time we discussed this, there were still platforms under support that didn't have xz easily available. >> 4. Meson uses git archive internally, but then unpacks and repacks the >> archive, which loses the ability to use git get-tar-commit-id. > > What do you use this for? IMO a more robust way to track the commit used > is to use gitattributes export-subst to write a `.git_archival.txt` file > containing the commit sha1 and other info -- this can be read even after > the file is extracted, which means it can also be used to bake the ID > into the built binaries e.g. as part of --version output. It's a marginal use case, for sure. But it is something that git provides tooling for that is universally available. Any alternative would be an ad-hoc solution that is specific to our project and would be different for the next project. >> 5. I have found that the tar archives created by meson and git archive >> include the files in different orders.  I suspect that the Python >> tarfile module introduces some either randomness or platform dependency. > > Different orders is meaningless, the question is whether the order is > internally consistent. Python uses sorted() to guarantee a stable order, > which may be a different algorithm than the one git-archive uses to > guarantee a stable order. But the order should be stable and that is > what matters. (FWIW, I couldn't reproduce this anymore, so maybe it's not actually an issue.) > Overall I feel like much of this is about requiring dist tarballs to be > byte-identical to other dist tarballs, although reproducible builds is > mainly about artifacts, not sources, and for sources it doesn't > generally matter unless the sources are ephemeral and generated > on-demand (in which case it is indeed very important to produce the same > tarball each time). The source tarball is, in a way, also an artifact. I think it's useful that others can easily independently verify that the produced tarball matches what they have locally. It's not an absolute requirement, but given that it is possible, it seems useful to take advantage of it. In a way, this also avoids the need for signing the tarball, which we don't do. So maybe that contributes to a different perspective.