Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gigr9-0003fX-Pk for pgsql-general@arkaria.postgresql.org; Sun, 13 Jan 2019 14:35:19 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gigr8-0002Uq-3y for pgsql-general@arkaria.postgresql.org; Sun, 13 Jan 2019 14:35:18 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gigr7-0002Uj-SJ for pgsql-general@lists.postgresql.org; Sun, 13 Jan 2019 14:35:17 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gigr4-0002gc-Qe for pgsql-general@lists.postgresql.org; Sun, 13 Jan 2019 14:35:17 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id x0DEZACM003458; Sun, 13 Jan 2019 09:35:10 -0500 From: Tom Lane To: Zach van Rijn cc: Pratik Parikh , pgsql-general@lists.postgresql.org Subject: Re: Static PostgreSQL Binaries (Linux + Windows) In-reply-to: <1547388806.4002.20.camel@zv.io> References: <1547351839.4002.17.camel@zv.io> <1547388806.4002.20.camel@zv.io> Comments: In-reply-to Zach van Rijn message dated "Sun, 13 Jan 2019 09:13:26 -0500" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <3456.1547390110.1@sss.pgh.pa.us> Date: Sun, 13 Jan 2019 09:35:10 -0500 Message-ID: <3457.1547390110@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Zach van Rijn writes: > Under the hood, the only major "technique" is wrapping the 'gcc' > command with flags such as '-static' to ensure that everything > is built correctly, and using reliable toolchains [1]. > There is one minor issue in that the postgres build scripts no > longer appear to support static building [2,3] so it'll attempt > to build files such as 'POSIX.so' etc. and these cause errors. Yup. > The workaround is simply to ignore these errors during build > until I or someone else can get around to supplying patches (in > the next week or so; I have other commitments). TBH, there's going to be zero community interest in such patches. There is no reason to avoid shared libraries, and they're an essential part of the modern Postgres build architecture --- particularly our extensibility story. Personally, I find your claim that purely-static linking is somehow a security advantage to be quite bizarre. All modern Linux distros actually forbid static linking, I believe, because it'd put them in an impossible rebuild situation when some low-level component requires an update --- possibly for security reasons. Are you going to promise immediate updates anytime glibc gets patched, across all the platforms you're proposing to support this on? regards, tom lane