Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-07-05 Thread Michael Paquier
On Sat, Jul 04, 2020 at 09:17:52PM +0200, Juan José Santamaría Flecha wrote: > Going through the open items in the commitfest, I see that this patch has > not been pushed. It still applies and solves the warning so, I am marking > it as RFC. Thanks, applied. I was actually waiting to see if you h

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-07-04 Thread Juan José Santamaría Flecha
On Tue, Jun 2, 2020 at 2:06 AM David Zhang wrote: > > On 2020-05-06 10:45 p.m., Michael Paquier wrote: > > On Wed, May 06, 2020 at 12:17:03AM +0200, Juan José Santamaría Flecha > wrote: > >> Please forgive me if I am being too nitpicky, but I find the comments a > >> little too verbose, a usage f

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-06-01 Thread David Zhang
Hi Michael, I performed a quick test for the path "msvc-build-init-v2.patch" using below cases: 1. perl build.pl 2. perl build.pl debug psql 3. perl build.pl RELEASE psql 4. perl build.pl deBUG psql 5. perl build.pl psql The above cases (case-insensitive) are all working great without any war

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-07 Thread Ranier Vilela
Em qui., 7 de mai. de 2020 às 02:04, Victor Wagner escreveu: > В Thu, 7 May 2020 09:14:33 +0900 > Michael Paquier пишет: > > > On Wed, May 06, 2020 at 03:58:15PM -0300, Ranier Vilela wrote: > > > Hacking pgbison.pl, to print PATH, shows that the path inside > > > pgbison.pl, returned to being th

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Michael Paquier
On Wed, May 06, 2020 at 12:17:03AM +0200, Juan José Santamaría Flecha wrote: > Please forgive me if I am being too nitpicky, but I find the comments a > little too verbose, a usage format might be more visual and easier to > explain: > > Usage: build [[CONFIGURATION] COMPONENT] > > The options ar

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Victor Wagner
В Wed, 6 May 2020 21:23:57 -0300 Ranier Vilela пишет: > > The perl is: > Win32 strawberry-perl 5.30.1.1 > This perl would have problems when compiling PL/Perl (see my letter about week ago), but it have no problems running various build scripts for Postgres. I'm using it with MSVisualStudio 20

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Victor Wagner
В Thu, 7 May 2020 09:14:33 +0900 Michael Paquier пишет: > On Wed, May 06, 2020 at 03:58:15PM -0300, Ranier Vilela wrote: > > Hacking pgbison.pl, to print PATH, shows that the path inside > > pgbison.pl, returned to being the original, without the addition of > > c:\perl\bin;c:\bin. my $out = $ENV

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Ranier Vilela
Em qua., 6 de mai. de 2020 às 21:14, Michael Paquier escreveu: > On Wed, May 06, 2020 at 03:58:15PM -0300, Ranier Vilela wrote: > > Hacking pgbison.pl, to print PATH, shows that the path inside pgbison.pl > , > > returned to being the original, without the addition of > c:\perl\bin;c:\bin. > > my

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Ranier Vilela
Em qua., 6 de mai. de 2020 às 21:08, Michael Paquier escreveu: > On Wed, May 06, 2020 at 02:11:34PM -0400, Andrew Dunstan wrote: > > We assume perl, flex and bison are in the PATH. That doesn't seem > > unreasonable, it's worked well for quite a long time. > > I recall that it is an assumption we

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Michael Paquier
On Wed, May 06, 2020 at 03:58:15PM -0300, Ranier Vilela wrote: > Hacking pgbison.pl, to print PATH, shows that the path inside pgbison.pl, > returned to being the original, without the addition of c:\perl\bin;c:\bin. > my $out = $ENV{PATH}; > print "Path after system call=$out\n"; > Path after syst

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Michael Paquier
On Wed, May 06, 2020 at 02:11:34PM -0400, Andrew Dunstan wrote: > We assume perl, flex and bison are in the PATH. That doesn't seem > unreasonable, it's worked well for quite a long time. I recall that it is an assumption we rely on since MSVC scripts are around, and that's rather easy to configur

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Ranier Vilela
Em qua., 6 de mai. de 2020 às 15:19, Ranier Vilela escreveu: > Em qua., 6 de mai. de 2020 às 14:14, Victor Wagner > escreveu: > >> В Wed, 6 May 2020 10:21:41 -0300 >> Ranier Vilela пишет: >> >> > Em qua., 6 de mai. de 2020 às 09:53, Michael Paquier >> > escreveu: >> > >> > > On Tue, May 05, 20

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Ranier Vilela
Em qua., 6 de mai. de 2020 às 14:14, Victor Wagner escreveu: > В Wed, 6 May 2020 10:21:41 -0300 > Ranier Vilela пишет: > > > Em qua., 6 de mai. de 2020 às 09:53, Michael Paquier > > escreveu: > > > > > On Tue, May 05, 2020 at 10:16:23AM +0300, Victor Wagner wrote: > > > > I agree, it is better.

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Andrew Dunstan
On 5/6/20 1:14 PM, Victor Wagner wrote: > В Wed, 6 May 2020 10:21:41 -0300 > Ranier Vilela пишет: > >> Em qua., 6 de mai. de 2020 às 09:53, Michael Paquier >> escreveu: >> >>> On Tue, May 05, 2020 at 10:16:23AM +0300, Victor Wagner wrote: I agree, it is better. >>> Thanks, applied and

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Victor Wagner
В Wed, 6 May 2020 10:21:41 -0300 Ranier Vilela пишет: > Em qua., 6 de mai. de 2020 às 09:53, Michael Paquier > escreveu: > > > On Tue, May 05, 2020 at 10:16:23AM +0300, Victor Wagner wrote: > > > I agree, it is better. > > > > Thanks, applied and back-patched down to 9.5. Now for the secon

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Ranier Vilela
Em qua., 6 de mai. de 2020 às 10:25, Ranier Vilela escreveu: > Em qua., 6 de mai. de 2020 às 10:21, Ranier Vilela > escreveu: > >> Em qua., 6 de mai. de 2020 às 09:53, Michael Paquier >> escreveu: >> >>> On Tue, May 05, 2020 at 10:16:23AM +0300, Victor Wagner wrote: >>> > I agree, it is better.

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Ranier Vilela
Em qua., 6 de mai. de 2020 às 10:21, Ranier Vilela escreveu: > Em qua., 6 de mai. de 2020 às 09:53, Michael Paquier > escreveu: > >> On Tue, May 05, 2020 at 10:16:23AM +0300, Victor Wagner wrote: >> > I agree, it is better. >> >> Thanks, applied and back-patched down to 9.5. Now for the second

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Ranier Vilela
Em qua., 6 de mai. de 2020 às 09:53, Michael Paquier escreveu: > On Tue, May 05, 2020 at 10:16:23AM +0300, Victor Wagner wrote: > > I agree, it is better. > > Thanks, applied and back-patched down to 9.5. Now for the second > problem of this thread.. > Sorry, no clue yet. I hacked the perl sourc

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-06 Thread Michael Paquier
On Tue, May 05, 2020 at 10:16:23AM +0300, Victor Wagner wrote: > I agree, it is better. Thanks, applied and back-patched down to 9.5. Now for the second problem of this thread.. -- Michael signature.asc Description: PGP signature

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-05 Thread Juan José Santamaría Flecha
On Tue, May 5, 2020 at 4:06 PM Michael Paquier wrote: > On Mon, May 04, 2020 at 03:42:20PM +0200, Juan José Santamaría Flecha > wrote: > > +1, seems like the way to go to me. > > Attached is a patch for that and I have gone with a simple solution, > with some bonus comments about the way things h

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-05 Thread Michael Paquier
On Mon, May 04, 2020 at 03:42:20PM +0200, Juan José Santamaría Flecha wrote: > +1, seems like the way to go to me. Attached is a patch for that and I have gone with a simple solution, with some bonus comments about the way things happen. Here are the patterns I tested for build.pl and the command

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-05 Thread Victor Wagner
В Tue, 5 May 2020 15:45:48 +0900 Michael Paquier пишет: > On Fri, May 01, 2020 at 12:48:17PM +0300, Victor Wagner wrote: > > Maybe. But probably original author of this code was afraid of using > > too long chain of ->{} in the string substitution. > > > > So, I left this style n place. > > >

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-04 Thread Michael Paquier
On Fri, May 01, 2020 at 12:48:17PM +0300, Victor Wagner wrote: > Maybe. But probably original author of this code was afraid of using > too long chain of ->{} in the string substitution. > > So, I left this style n place. > > Nonetheless, using qq wouldn't save us from doubling backslashes. Loo

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-04 Thread Juan José Santamaría Flecha
On Mon, May 4, 2020 at 2:18 PM Michael Paquier wrote: > On Mon, May 04, 2020 at 09:45:54AM +0200, Juan José Santamaría Flecha > wrote: > > I think these are two different issues, python PATH and build.pl > warnings. > > For the later, you can check woodloose logs and see the warning after > > com

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-04 Thread Michael Paquier
On Mon, May 04, 2020 at 09:45:54AM +0200, Juan José Santamaría Flecha wrote: > I think these are two different issues, python PATH and build.pl warnings. > For the later, you can check woodloose logs and see the warning after > commit 8f00d84afc. Oh, indeed. I somewhat managed to miss these in th

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-04 Thread Ranier Vilela
Em seg., 4 de mai. de 2020 às 02:58, Michael Paquier escreveu: > On Sun, May 03, 2020 at 04:23:24PM -0300, Ranier Vilela wrote: > > I don't know if it applies to the same case, but from the moment I > > installed python on the development machine, the Postgres build stopped > > working correctly.

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-04 Thread Juan José Santamaría Flecha
On Mon, May 4, 2020 at 7:58 AM Michael Paquier wrote: > > > Warning from build.pl > > Use of uninitialized value $ARGV[0] in uc at build.pl line 44. > > Use of uninitialized value $ARGV[0] in uc at build.pl line 48. > > Hmm. We have buildfarm machines using the MSVC scripts and Python, > see for

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-03 Thread Michael Paquier
On Sun, May 03, 2020 at 04:23:24PM -0300, Ranier Vilela wrote: > I don't know if it applies to the same case, but from the moment I > installed python on the development machine, the Postgres build stopped > working correctly. > Although perl, flex and bison are available in the path, the build doe

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-03 Thread Ranier Vilela
Em qui., 30 de abr. de 2020 às 09:06, Victor Wagner escreveu: > > Collegues, > > Accidently I've come over minor bug in the Mkvcbuild.pm. > It happens, that it doesn't tolerate spaces in the $config->{python} > path, because it want to call python in order to find out version, > prefix and so on,

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-01 Thread Victor Wagner
В Fri, 1 May 2020 17:52:15 +0900 Michael Paquier пишет: > On Thu, Apr 30, 2020 at 03:06:08PM +0300, Victor Wagner wrote: > > Fix is very simple, see attach. > > > > Patch is made against REL_12_STABLE, but probably applicable to > > other versions as well. > > Indeed, thanks. > > >

Re: Postgres Windows build system doesn't work with python installed in Program Files

2020-05-01 Thread Michael Paquier
On Thu, Apr 30, 2020 at 03:06:08PM +0300, Victor Wagner wrote: > Fix is very simple, see attach. > > Patch is made against REL_12_STABLE, but probably applicable to other > versions as well. Indeed, thanks. > my $pythonprog = "import sys;print(sys.prefix);" > . "pri

Postgres Windows build system doesn't work with python installed in Program Files

2020-04-30 Thread Victor Wagner
Collegues, Accidently I've come over minor bug in the Mkvcbuild.pm. It happens, that it doesn't tolerate spaces in the $config->{python} path, because it want to call python in order to find out version, prefix and so on, and doesn't properly quote command. Fix is very simple, see attach. Patch