Re: BUG #15889: PostgreSQL failed to build due to error MSB8020 with MSVC on windows

From: Haribabu Kommi <kommi(dot)haribabu(at)gmail(dot)com>
To: Michael Paquier <michael(at)paquier(dot)xyz>
Cc: Juan José Santamaría Flecha <juanjo(dot)santamaria(at)gmail(dot)com>, gaolin01(at)beyondsoft(dot)com, pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: BUG #15889: PostgreSQL failed to build due to error MSB8020 with MSVC on windows
Date: 2019-07-10 09:53:51
Message-ID: CAJrrPGfdcqrURmYX0zw33DXAdZiVZdHkUBo=A2Y5zfmp1fmtnA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Thu, 4 Jul 2019 at 18:32, Michael Paquier <michael(at)paquier(dot)xyz> wrote:

> On Thu, Jul 04, 2019 at 10:18:44AM +0200, Juan José Santamaría Flecha
> wrote:
> > In that building environment, if you edit
> > ".\src\tools\msvc\buildenv.pl" to add the following line:
> >
> > $ENV{MSBFLAGS}="/p:PlatformToolset=v141";
> >
> > Does it work as workaround for you?
> >
> > Anyhow, could you please share what nmake version are you using?
>
> As a side thought, we could also move away from nmake when it comes to
> find out the version of Visual Studio used if Microsoft is lazy with
> nmake's version number. For example we could consider using
> "MSBuild.exe -version" and parse its output. This reports 16.1.XX.YY
> for me with VS 2019, and 14.0.XX.YY with VS 2015.
>
> Not sure how portable that it though past those versions. Still, on
> HEAD and v12, we only support VS 2013 and newer versions, so we could
> integrate with it easily.
>

I agree that we can think of using MSBuild.exe instead of nmake. I am also
not sure whether MSBuild is available in all the visual studio versions
[1].

[1] - https://en.wikipedia.org/wiki/MSBuild

Regards,
Haribabu Kommi

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message David Rowley 2019-07-10 10:06:39 Re: PG11 - Multiple Key Range Partition
Previous Message David Rowley 2019-07-10 09:52:35 Re: FDW does not push down LIMIT & ORDER BY with sharding (partitions)