From: | Eddie Stanley <eddiewould(at)paradise(dot)net(dot)nz> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Cc: | mux(at)elvis(dot)mu(dot)org |
Subject: | Frustrating issue with PGXS |
Date: | 2007-06-25 11:42:28 |
Message-ID: | 1182771748.467faa24a9ae3@www.paradise.net.nz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
I spent the best part of the day trying to work this out - I was working on a
system setup with PG 8.2, and wanted to work with 8.3 for development.
I installed as follows:
1. CVS checkout
2. ./configure prefix=~/install_dir
3. gmake prefix=~/install_dir
4. gmake install prefix=~/install_dir
Got a datastore up and running with initdb; created some test tables, everything
seemed to be fine.
The problem came when I wanted to build a simple C function - I used the
following makefile:
MODULES = example
PGXS := $(shell ~/install_dir/bin/pg_config --pgxs)
include $(PGXS)
The program compiled fine, however I noticed the compilation was refering to
files in /usr/pkg (from the 8.2 installation). I would have thought specifing
the version of pg_config from the 8.3 installation would be sufficent, but it
wasn't.
In /lib/postgresql/pgxs/src/Makefile.global, I needed to change
PG_CONFIG = pg_config
to
PG_CONFIG = ~/install_dir/bin/pg_config
Could this have been avoided if the Makefile.global had
PG_CONFIG = $(prefix)/bin/pg_config
?
Eddie
From | Date | Subject | |
---|---|---|---|
Next Message | Magnus Hagander | 2007-06-25 12:08:25 | Re: Frustrating issue with PGXS |
Previous Message | Zdenek Kotala | 2007-06-25 10:37:35 | New Zealand - TZ change |