Re: Configurable location for extension .control files

From: Heikki Linnakangas <hlinnaka(at)iki(dot)fi>
To: Oskari Saarenmaa <os(at)ohmu(dot)fi>, Jim Nasby <Jim(dot)Nasby(at)BlueTreble(dot)com>, Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr>, Andres Freund <andres(at)2ndquadrant(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Oliver Charles <ollie(at)ocharles(dot)org(dot)uk>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Configurable location for extension .control files
Date: 2015-07-30 10:15:56
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On 07/02/2015 11:37 PM, Oskari Saarenmaa wrote:
> I'm somewhat interested in both #1 & #2 for other projects, but I wrote
> this patch to address #3, i.e. to simplify the test setup we have in
> place for pgmemcache
> ( and other
> extensions. I'd like to be able to set up a local PG cluster in /tmp or
> some other location and load the extensions I just built in there.

Now that's a laudable goal. It indeed would be nice to be able to do
"make check" to test an extension, using pgxs. The way "make check"
within the PostgreSQL source tree works is that it performs "make
install" to install PostgreSQL a temporary location, and installs the
extension to that. We can't use "make install" to create a new
PostgreSQL installation in an extension, but perhaps you could have a
substitute of that that copies an existing installation to a temporary
location. I hacked that pgmemcache script to do just that,
see attached. That's usable for pgmemcache as it is, but for a general
facility, you'd need to put that logic into pgxs instead, and it should
also take care of running initdb and starting and stopping the cluster.
But pg_regress can already do those things, so that should be easy.

So, I think that's the direction this should be going. In summary, the
goal is to make "make check" to work for extensions, and the way to do
that is to teach pgxs to create a temporary installation.

- Heikki

Attachment Content-Type Size
pgmemcache-tmp-install-1.patch application/x-patch 3.2 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Etsuro Fujita 2015-07-30 10:15:59 Re: Foreign join pushdown vs EvalPlanQual
Previous Message Rajeev rastogi 2015-07-30 09:55:11 Re: Autonomous Transaction is back