Received: from malur.postgresql.org ([2a02:16a8:dc51::56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fhdBX-000167-Em for pgsql-hackers@arkaria.postgresql.org; Mon, 23 Jul 2018 15:55:44 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1fhdBV-0005S2-H4 for pgsql-hackers@arkaria.postgresql.org; Mon, 23 Jul 2018 15:55:41 +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_SHA384:256) (Exim 4.89) (envelope-from ) id 1fhdBU-0005Rk-CK for pgsql-hackers@lists.postgresql.org; Mon, 23 Jul 2018 15:55:41 +0000 Received: from out1-smtp.messagingengine.com ([66.111.4.25]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fhdBO-0004v0-TL for pgsql-hackers@postgresql.org; Mon, 23 Jul 2018 15:55:39 +0000 Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id CBB2621F00; Mon, 23 Jul 2018 11:55:32 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Mon, 23 Jul 2018 11:55:32 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=anarazel.de; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm2; bh=8Y6TCKrZUy22Wcs/rZSWhpHUvolKmwH5nvcf79b+ehQ=; b=vIBDn9AV EGPdSTjSF8LjdERAnrkteJokZx/nWe4jJmEZV6z4NyO4GrJe9uB77QdSn8oj4UJG j3uMmoh6Y8OQLNw7Y8qZFQIu8U3JWxwXF6P5FkWubuJLawTZcBg9P7tm2/fv7gJ+ wThVBesKhceCavzSW2u9YB4XqiPzKiOjU04WnacosZKPSMtw2p99WjRHV2DzxNpi Vhlu4jH9VAp3P0T1AQ3YBtKa5+WQs8Y/wW7zgUElurhlvnOOW9kfMtaLhcaQ1uHO qyIP6+dNyK2U6sSsvCZk6xM0MjaQVb0JONSZyLdOf1TtMdrl5DUeAOt5ufUaMVyH 5Bo7bTMYQyWEqQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm3; bh=8Y6TCKrZUy22Wcs/rZSWhpHUvolKm wH5nvcf79b+ehQ=; b=OADB4gJflM8zaVaHxlqfaSEI6q4zYrkSXlMBGNpeGoO5v zWWhzySAX4SiCRdgsv4il6xJ5k3FCYuofEwDXW+zz3baSGGf+ShX74A9RSiAK68R 3z22mg8pMUUiahwpYX1glOXta7jvxIcVEyWQYJBz9Xk1+b2p5U8WUOIUmUPoJR9o S6pVkn3bii0Qntz6/F0sGNfT9gHcAA5UwKTH8qgRwy2Ww3AakUqKW76ulnQuzyfX ws3jJDjHyQBIj7627ICBdu1MzyrZ8/Ng3l4pGYygWNZ1ux+Lg9qThgdZaz6Ji3kJ znb6txYXJE/+qYhoJTID+vu+/VzSX0Z02/wGYCtIQ== X-ME-Proxy: X-ME-Sender: Received: from intern.anarazel.de (c-98-210-140-171.hsd1.ca.comcast.net [98.210.140.171]) by mail.messagingengine.com (Postfix) with ESMTPA id E2CCA1026E; Mon, 23 Jul 2018 11:55:31 -0400 (EDT) Date: Mon, 23 Jul 2018 08:55:30 -0700 From: Andres Freund To: Peter Eisentraut Cc: Tom Lane , Michael Paquier , Stephen Frost , Andrew Gierth , pgsql-hackers@postgresql.org Subject: Re: Should contrib modules install .h files? Message-ID: <20180723155530.r5r72i2xtcs2d5fj@alap3.anarazel.de> References: <87y3euomjh.fsf@news-spur.riddles.org.uk> <87tvpinfr4.fsf@news-spur.riddles.org.uk> <63444.1530537990@sss.pgh.pa.us> <12ba9c72-504f-b911-f0ce-1dff2826fa5b@2ndquadrant.com> <87k1q8kokq.fsf@news-spur.riddles.org.uk> <20180723014208.GE27724@tamriel.snowman.net> <20180723032405.GF2854@paquier.xyz> <21149.1532319353@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 2018-07-23 17:22:16 +0200, Peter Eisentraut wrote: > On 23.07.18 06:15, Tom Lane wrote: > > Michael Paquier writes: > >> On Sun, Jul 22, 2018 at 09:42:08PM -0400, Stephen Frost wrote: > >>> So, +1 from me for having a directory for each extension. > > > >> So, like Stephen, that's a +1 from me. > > > > Same here. One-file-per-extension is too strongly biased to tiny > > extensions (like most of our contrib examples). > > Nobody said anything about one-file-per-extension. You can of course > have hstore_this.h and hstore_that.h or if you want to have many, use > postgis/this.h and postgis/that.h. That's how every C package in the > world works. We don't need to legislate further here other than, use > sensible naming. PGXS provides a certain way of doing things. It's far from insane for us to procscribe that we go for $extension/. I fail to see any sort of advantage of using $extension_$header.h. It only serves to create additional work. > Also, let's recall that the point of this exercise is that you want to > install the header files so that you can build things (another > extension) that somehow interacts with those extensions. Then, even if > you put things in separate directories per extension, you still need to > make sure that all the installed header files don't clash, since you'll > be adding the -I options of several of them. I'd suggest just using the name with the $extension/ prefix going forward. > > I don't have a real strong opinion on whether it's too late to > > push this into v11. I do not think it'd break anything other than > > packagers' lists of files to be installed ... but it does seem > > like a new feature, and we're past feature freeze. > > Certainly a new feature. I suggest submitting it to the next commit fest. Given that there seems to be fairly widespread agreement, anyone that commented but you, and the patch has been reviewed, I see zero reason to wait for the next CF for a committer's patch. Greetings, Andres Freund