Re: Making pgxs builds work with a relocated installation - Mailing list pgsql-hackers

From Magnus Hagander
Subject Re: Making pgxs builds work with a relocated installation
Date
Msg-id 6BCB9D8A16AC4241919521715F4D8BCE6C79FA@algol.sollentuna.se
Whole thread Raw
In response to Making pgxs builds work with a relocated installation  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
> > > > The other open issue in this area was that on Windows,
> > > pg_config needs
> > > > to return space-free path names to avoid breaking the
> > > makefiles.  It
> > > > was suggested that this could be handled by passing
> > > pg_config's result
> > > > path names through GetShortPathName() on that platform.
> > > That sounds
> > > > OK to me but I'm not in a position to write or test such a
> > > patch; can
> > > > someone take care of that?
> > >
> > > At the risk of getting squished in the rush to help, if
> noone else
> > > volunteers I'll try to find some time.
> >
> > Missed this one when it came through the first time. Note: Not
> > volunteering, just commenting on the how-fix :P
> >
> > 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.
>
> If it's disabled, then they aren't going to be able to use
> short names anyway, therefore we can't do much about it. If
> you see what I mean!

Well, are we sure thare are no other ways? Either some funky quoting or
backslash-escaping spaces or something like that?


> If GetShortPathName() just returns what was passed to it in
> such cases, then at least we won't be any worse off than we are now.

Right. That'll have to be checked though, the API docs don't seem to
talk about that. Could be it gives you NULL or something equally evil..

//Magnus


pgsql-hackers by date:

Previous
From: "Dave Page"
Date:
Subject: Re: Making pgxs builds work with a relocated installation
Next
From: "Dave Page"
Date:
Subject: Re: Making pgxs builds work with a relocated installation