Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mKiCs-0003Nj-IE for pgsql-general@arkaria.postgresql.org; Mon, 30 Aug 2021 14:24:14 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1mKiCr-0001Ow-Hb for pgsql-general@arkaria.postgresql.org; Mon, 30 Aug 2021 14:24:13 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mKiCr-0001Oo-8z for pgsql-general@lists.postgresql.org; Mon, 30 Aug 2021 14:24:13 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mKiCp-0006mX-75 for pgsql-general@lists.postgresql.org; Mon, 30 Aug 2021 14:24:12 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 17UEO6121349738; Mon, 30 Aug 2021 10:24:06 -0400 From: Tom Lane To: Mario Emmenlauer cc: PostgreSQL General Subject: Re: lib and share are installed differently, but why? In-reply-to: <8b1a13e4-5454-cdb7-b9d3-d8aa36599ccf@emmenlauer.de> References: <8b1a13e4-5454-cdb7-b9d3-d8aa36599ccf@emmenlauer.de> Comments: In-reply-to Mario Emmenlauer message dated "Mon, 30 Aug 2021 12:53:54 +0200" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <1349736.1630333446.1@sss.pgh.pa.us> Date: Mon, 30 Aug 2021 10:24:06 -0400 Message-ID: <1349737.1630333446@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Mario Emmenlauer writes: > I've been building and using PostgreSQL from source for a few years > now, thanks for the awesome work! > Since upgrading from 12.5 to 12.8, I've found a problem that I can > not resolve myself. We build PostgreSQL twice, once to folder A, and > once to folder B. This is because A is more easily deployable, while > B holds all our development build targets. The only difference in > the two builds is the change in `--prefix` for configure. Everything > else is identical, and both builds start from a clean directory. > But I see a difference in the installations: > - The contents of `share` go to A/share/ vs B/share/postgresql/ > - The contents of `lib` go to B/lib vs B/lib/postgresql/ You didn't say exactly what "A" and "B" stand for, but I'll bet that the string "A" includes "pgsql" or "postgres". Makefile.global makes some installation path changes when that's not true, e.g. pkglibdir = $(libdir) ifeq "$(findstring pgsql, $(pkglibdir))" "" ifeq "$(findstring postgres, $(pkglibdir))" "" override pkglibdir := $(pkglibdir)/postgresql endif endif This behavior is pretty ancient; I'm quite sure it didn't change between 12.5 and 12.8. So I speculate that you made some change in your build process that you didn't mention. regards, tom lane