Обсуждение: BUG #13689: Build failed pg9.4.5 with mingw5.1

Поиск
Список
Период
Сортировка

BUG #13689: Build failed pg9.4.5 with mingw5.1

От
kangjoni76@gmail.com
Дата:
The following bug has been logged on the website:

Bug reference:      13689
Logged by:          kang joni
Email address:      kangjoni76@gmail.com
PostgreSQL version: 9.4.5
Operating system:   Windows SysWow64
Description:

Invalid conversion ForkNumber to int...
error build failed ForkNumber type doesn't have operator++.
This happen in src/common/relpath.c:52 and also at line 86.

Re: BUG #13689: Build failed pg9.4.5 with mingw5.1

От
Bruce Momjian
Дата:
On Tue, Oct 20, 2015 at 04:37:37AM +0000, kangjoni76@gmail.com wrote:
> The following bug has been logged on the website:
>
> Bug reference:      13689
> Logged by:          kang joni
> Email address:      kangjoni76@gmail.com
> PostgreSQL version: 9.4.5
> Operating system:   Windows SysWow64
> Description:
>
> Invalid conversion ForkNumber to int...
> error build failed ForkNumber type doesn't have operator++.
> This happen in src/common/relpath.c:52 and also at line 86.

Wow, we are incrementing an enum here.  Is that legal?  What compiler
are you using?

--
  Bruce Momjian  <bruce@momjian.us>        http://momjian.us
  EnterpriseDB                             http://enterprisedb.com

+ As you are, so once was I. As I am, so you will be. +
+ Roman grave inscription                             +

Re: BUG #13689: Build failed pg9.4.5 with mingw5.1

От
Tom Lane
Дата:
Bruce Momjian <bruce@momjian.us> writes:
> On Tue, Oct 20, 2015 at 04:37:37AM +0000, kangjoni76@gmail.com wrote:
>> Invalid conversion ForkNumber to int...
>> error build failed ForkNumber type doesn't have operator++.
>> This happen in src/common/relpath.c:52 and also at line 86.

> Wow, we are incrementing an enum here.  Is that legal?  What compiler
> are you using?

Possibly C++ doesn't allow that?  But if so, it's user error.
Postgres is written in C not C++.

(I could see a compiler issuing a warning here that forkNum will
get incremented past the declared range of the enum.  But that
doesn't seem to be what's being reported.)

            regards, tom lane

Re: BUG #13689: Build failed pg9.4.5 with mingw5.1

От
kang joni
Дата:
On Tuesday, October 20, 2015, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Bruce Momjian <bruce@momjian.us> writes:
>> On Tue, Oct 20, 2015 at 04:37:37AM +0000, kangjoni76@gmail.com wrote:
>>> Invalid conversion ForkNumber to int...
>>> error build failed ForkNumber type doesn't have operator++.
>>> This happen in src/common/relpath.c:52 and also at line 86.
>
>> Wow, we are incrementing an enum here.  Is that legal?  What compiler
>> are you using?
>
> Possibly C++ doesn't allow that?  But if so, it's user error.
> Postgres is written in C not C++.
>
> (I could see a compiler issuing a warning here that forkNum will
> get incremented past the declared range of the enum.  But that
> doesn't seem to be what's being reported.)
>
>                         regards, tom lane
>


Ah yes this is my conf faults here, I don't know if this either msys2 bug
or mingw32-make.exe. Firstly, I moved make.exe to some folder, I thought
that make.exe was name polluting with my mingw32-make and brought make.exe
back to msys /usr/bin folder. And the error happen. I should compile enter
sh.exe mode and type /usr/bin/make.exe -j2 instead of make -j2.

I have another struggle that when would be compilable release postgresql
for native MSVC2015 build came out? I have another needs for using
plpython3 on windows or this should be moved to another bug report
postgresql vs2015 build ? thanks