Re: got stuck in pglogical upgrade on FreeBSD - Mailing list pgsql-general

From Rahul Chordiya
Subject Re: got stuck in pglogical upgrade on FreeBSD
Date
Msg-id CAFySG5GAhN2fxsJRro1sF_A2vE2tGZ34N1QTeGgaBTVtUwuYsg@mail.gmail.com
Whole thread Raw
In response to Re: got stuck in pglogical upgrade on FreeBSD  (Adrian Klaver <adrian.klaver@aklaver.com>)
Responses Re: got stuck in pglogical upgrade on FreeBSD
List pgsql-general
Hi,
Sorry for delayed response.

The first error is:

pglogical_fe.c:54:7: error: implicit declaration of function 'WIFEXITED' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
if (WIFEXITED(ret))
^
pglogical_fe.c:55:124: error: implicit declaration of function 'WEXITSTATUS' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
 ...fprintf(stderr, "find_other_exec_version: couldn't read output of \"%s\": %d (exited with return code %d)\n", cmd, ret, WEXITSTATUS(ret));
^
pglogical_fe.c:56:12: error: implicit declaration of function 'WIFSIGNALED' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
else if (WIFSIGNALED(ret))
^
pglogical_fe.c:57:119: error: implicit declaration of function 'WTERMSIG' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
fprintf(stderr, "find_other_exec_version: couldn't read output of \"%s\": %d (exited with signal %d)\n", cmd, ret, WTERMSIG(ret));
  ^
4 errors generated.

Header Added are:   

pglogical_fe.c ==>  

#include <sys/types.h>
#include <sys/wait.h>


And Second error is:

pglogical_apply_spi.c:588:8: error: implicit declaration of function 'htonl' is invalid in C99
      [-Werror,-Wimplicit-function-declaration]
        buf = htonl((uint32) val);
              ^
pglogical_apply_spi.c:600:8: error: implicit declaration of function 'htons' is invalid in C99
      [-Werror,-Wimplicit-function-declaration]
        buf = htons((uint16) val);
              ^
2 errors generated.

Header Added is: 
pglogical_apply_spi.c  =>> #include <arpa/inet.h>


After adding these .h file we are able to successfully gmake and install.



On Fri, Jun 21, 2019 at 9:57 PM Adrian Klaver <adrian.klaver@aklaver.com> wrote:
On 6/21/19 9:25 AM, Rahul Chordiya wrote:
> Yes, I did install via source using gmake as make command was not working.
> I also need to include some (.h) header file as gmake throwing some
> dependency error.

The errors and the header files are?

>
> On Fri, 21 Jun, 2019, 9:41 PM Adrian Klaver, <adrian.klaver@aklaver.com
> <mailto:adrian.klaver@aklaver.com>> wrote:
>
>     On 6/21/19 9:07 AM, Rahul Chordiya wrote:
>      > Yes and yes.
>      > Also tried to completely clear slave data directory and setup fresh
>      > subscribe & subscription.
>      >
>
>     I assume you compiled it from source. Where there any errors in the
>     make
>     and/or install stops?
>
>     Does the system log show anything relevant?
>
>
>
>     --
>     Adrian Klaver
>     adrian.klaver@aklaver.com <mailto:adrian.klaver@aklaver.com>
>


--
Adrian Klaver
adrian.klaver@aklaver.com


--
Thanks & Regards

Rahul Chordiya
Tech-Geek && DevOps && Full Stack Developer
Mobile: +91 998 153 4313

🌳

 Please do not print this email unless absolutely necessary. Go GREEN, Go PAPERLESS 🌳



pgsql-general by date:

Previous
From: Karl Martin Skoldebrand
Date:
Subject: sequences
Next
From: Thiemo Kellner
Date:
Subject: Re: sequences