Skip site navigation (1) Skip section navigation (2)

Re: Making pgxs builds work with a relocated installation

From: "Dave Page" <dpage(at)vale-housing(dot)co(dot)uk>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>,"Magnus Hagander" <mha(at)sollentuna(dot)net>
Cc: "Peter Eisentraut" <peter_e(at)gmx(dot)net>,<pgsql-hackers(at)postgresql(dot)org>,"PostgreSQL-patches" <pgsql-patches(at)postgresql(dot)org>
Subject: Re: Making pgxs builds work with a relocated installation
Date: 2005-09-28 12:43:22
Message-ID: E7F85A1B5FF8D44C8A1AF6885BC9A0E4CC2F76@ratbert.vale-housing.co.uk (view raw or flat)
Thread:
Lists: pgsql-hackerspgsql-patches
 

> -----Original Message-----
> From: Tom Lane [mailto:tgl(at)sss(dot)pgh(dot)pa(dot)us] 
> Sent: 27 September 2005 18:57
> To: Magnus Hagander
> Cc: Dave Page; Peter Eisentraut; pgsql-hackers(at)postgresql(dot)org
> Subject: Re: [HACKERS] Making pgxs builds work with a 
> relocated installation 
> 
> "Magnus Hagander" <mha(at)sollentuna(dot)net> writes:
> > Using GetShortPathName() will break on any system that has disabled
> > short filename generatino, which IIRC is a recommended best practice
> > both for performance and for security in legacy apps. I 
> don't know what
> > it does, but probably it will just return the same long path again.
> 
> Yuck.  Anyone have another idea on coping with space-containing
> pathnames?  I suppose we could try to quote the path 
> variables properly
> in all the makefiles, but that sure seems like a painful proposition.

Actually it seems to work quite nicely - on Windows 2000 with short
names disabled it generates paths like:

C:\PROGRA~1\PostgreSQL\8.1-beta2\bin

Ie, it still fixes the spaces, but leaves the long bits, umm, long. With
short names enabled (on XP), you get:

C:\PROGRA~1\POSTGR~1\827E4~1.1-B\bin

Which is truly hideous, but works as expected in cmd.exe and Msys.

Patch attached that does this, and doubles up on the backslashes to keep
msys/make happy. Cmd.exe doesn't seem to care about the double
backslashes.

Regards, Dave

Attachment: pg_config c.diff
Description: application/octet-stream (4.6 KB)

pgsql-hackers by date

Next:From: Alvaro HerreraDate: 2005-09-28 13:15:54
Subject: Re: Making pgxs builds work with a relocated installation
Previous:From: Dmitry KarasikDate: 2005-09-28 12:36:04
Subject: execution of prepared statements leaks memory

pgsql-patches by date

Next:From: Pavel StehuleDate: 2005-09-28 14:30:54
Subject: SQL/XML publishing function experimental patch II
Previous:From: Tom LaneDate: 2005-09-28 04:14:19
Subject: Re: Proposed p.tch for sequence-renaming problems

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group