Re: fmgroids.h not installed by "make install" in VPATH

Lists: pgsql-hackers
From: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
To: Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: fmgroids.h not installed by "make install" in VPATH
Date: 2009-07-07 23:09:20
Message-ID: 20090707230920.GV7694@alvh.no-ip.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Hi,

It seems our makefiles fail to install fmgroids.h by "make install" in a
VPATH build.

The reason is that they do this (src/include/Makefile)

for dir in $(SUBDIRS); do \
cp $(srcdir)/$$dir/*.h '$(DESTDIR)$(includedir_server)'/$$dir/ || exit; \
chmod $(INSTALL_DATA_MODE) '$(DESTDIR)$(includedir_server)'/$$dir/*.h || exit; \
done

However, fmgroids.h is a symlink in the builddir, not present in the sourcedir.
I think in a regular build it should install but I can't confirm it
because I don't have one handy.

There are a few other symlinks in src/include:

./dynloader.h
./pg_config_os.h
./utils/fmgroids.h
./parser/parse.h

pg_config_os.h is installed manually. Not sure of the usefulness of
installing dynloader.h and parse.h; fmgroids.h is needed to build the
EDB pldebugger so I think it should be installed. (Right now I think
the debugger forces you to build in-tree.)

I think the solution is to treat fmgroids.h just like pg_config_os.h,
i.e. add a line like this:

$(INSTALL_DATA) utils/fmgroids.h '$(DESTDIR)/$(includedir_server)/utils'

BTW: do we really need to install the win32 headers on non-win32 builds?

--
Alvaro Herrera http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support


From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: pgsql-hackers(at)postgresql(dot)org
Cc: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
Subject: Re: fmgroids.h not installed by "make install" in VPATH
Date: 2009-07-17 08:03:07
Message-ID: 200907171103.07768.peter_e@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Wednesday 08 July 2009 02:09:20 Alvaro Herrera wrote:
> It seems our makefiles fail to install fmgroids.h by "make install" in a
> VPATH build.

> I think the solution is to treat fmgroids.h just like pg_config_os.h,
> i.e. add a line like this:
>
> $(INSTALL_DATA) utils/fmgroids.h '$(DESTDIR)/$(includedir_server)/utils'

The fix looks right. Has it been applied?


From: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: fmgroids.h not installed by "make install" in VPATH
Date: 2009-07-18 17:14:20
Message-ID: 20090718171420.GA4938@alvh.no-ip.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Peter Eisentraut wrote:
> On Wednesday 08 July 2009 02:09:20 Alvaro Herrera wrote:
> > It seems our makefiles fail to install fmgroids.h by "make install" in a
> > VPATH build.
>
> > I think the solution is to treat fmgroids.h just like pg_config_os.h,
> > i.e. add a line like this:
> >
> > $(INSTALL_DATA) utils/fmgroids.h '$(DESTDIR)/$(includedir_server)/utils'
>
> The fix looks right. Has it been applied?

Nope, and I'm away right now so feel free.

--
Alvaro Herrera http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.


From: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: fmgroids.h not installed by "make install" in VPATH
Date: 2009-07-20 18:36:06
Message-ID: 20090720183606.GP4938@alvh.no-ip.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Peter Eisentraut wrote:
> On Wednesday 08 July 2009 02:09:20 Alvaro Herrera wrote:
> > It seems our makefiles fail to install fmgroids.h by "make install" in a
> > VPATH build.
>
> > I think the solution is to treat fmgroids.h just like pg_config_os.h,
> > i.e. add a line like this:
> >
> > $(INSTALL_DATA) utils/fmgroids.h '$(DESTDIR)/$(includedir_server)/utils'
>
> The fix looks right. Has it been applied?

FWIW I intend to apply it to HEAD and 8.4 only; if you think it should
be backpatched further back please say so.

--
Alvaro Herrera http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support


From: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: fmgroids.h not installed by "make install" in VPATH
Date: 2009-07-20 20:50:00
Message-ID: 20090720205000.GA32074@alvh.no-ip.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Peter Eisentraut wrote:
> On Wednesday 08 July 2009 02:09:20 Alvaro Herrera wrote:
> > It seems our makefiles fail to install fmgroids.h by "make install" in a
> > VPATH build.
>
> > I think the solution is to treat fmgroids.h just like pg_config_os.h,
> > i.e. add a line like this:
> >
> > $(INSTALL_DATA) utils/fmgroids.h '$(DESTDIR)/$(includedir_server)/utils'
>
> The fix looks right. Has it been applied?

Applied and backpatched up to 8.2. (It didn't apply cleanly to 8.1).

--
Alvaro Herrera http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support