CyberDem0n / bg_mon

Background worker for monitoring PostgreSQL
MIT License
66 stars 11 forks source link

error during bg_mon build for PostgreSQL 15 #54

Closed vitabaks closed 1 year ago

vitabaks commented 1 year ago

error during bg_mon build for PostgreSQL 15 (beta 3)

Cloning into 'bg_mon'...
gcc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Werror=vla -Wendif-labels -Wmissing-format-attribute -Wimplicit-fallthrough=3 -Wcast-function-type -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard -Wno-format-truncation -Wno-stringop-truncation -g -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -fno-omit-frame-pointer -fPIC -DUIFILE='"/usr/share/postgresql/15/contrib/bg_mon.html"' -DHAS_LIBBROTLI -I. -I./ -I/usr/include/postgresql/15/server -I/usr/include/postgresql/internal  -Wdate-time -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -I/usr/include/libxml2   -c -o bg_mon.o bg_mon.c
gcc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Werror=vla -Wendif-labels -Wmissing-format-attribute -Wimplicit-fallthrough=3 -Wcast-function-type -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard -Wno-format-truncation -Wno-stringop-truncation -g -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -fno-omit-frame-pointer -fPIC -DUIFILE='"/usr/share/postgresql/15/contrib/bg_mon.html"' -DHAS_LIBBROTLI -I. -I./ -I/usr/include/postgresql/15/server -I/usr/include/postgresql/internal  -Wdate-time -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -I/usr/include/libxml2   -c -o brotli_utils.o brotli_utils.c
gcc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Werror=vla -Wendif-labels -Wmissing-format-attribute -Wimplicit-fallthrough=3 -Wcast-function-type -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard -Wno-format-truncation -Wno-stringop-truncation -g -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -fno-omit-frame-pointer -fPIC -DUIFILE='"/usr/share/postgresql/15/contrib/bg_mon.html"' -DHAS_LIBBROTLI -I. -I./ -I/usr/include/postgresql/15/server -I/usr/include/postgresql/internal  -Wdate-time -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -I/usr/include/libxml2   -c -o disk_stats.o disk_stats.c
gcc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Werror=vla -Wendif-labels -Wmissing-format-attribute -Wimplicit-fallthrough=3 -Wcast-function-type -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard -Wno-format-truncation -Wno-stringop-truncation -g -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -fno-omit-frame-pointer -fPIC -DUIFILE='"/usr/share/postgresql/15/contrib/bg_mon.html"' -DHAS_LIBBROTLI -I. -I./ -I/usr/include/postgresql/15/server -I/usr/include/postgresql/internal  -Wdate-time -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -I/usr/include/libxml2   -c -o net_stats.o net_stats.c
gcc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Werror=vla -Wendif-labels -Wmissing-format-attribute -Wimplicit-fallthrough=3 -Wcast-function-type -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard -Wno-format-truncation -Wno-stringop-truncation -g -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -fno-omit-frame-pointer -fPIC -DUIFILE='"/usr/share/postgresql/15/contrib/bg_mon.html"' -DHAS_LIBBROTLI -I. -I./ -I/usr/include/postgresql/15/server -I/usr/include/postgresql/internal  -Wdate-time -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -I/usr/include/libxml2   -c -o postgres_stats.o postgres_stats.c
postgres_stats.c: In function ‘get_pg_stat_activity’:
postgres_stats.c:1131:3: error: too few arguments to function ‘InitPostgres’
 1131 |   InitPostgres("postgres", InvalidOid, NULL, InvalidOid, NULL, false);
      |   ^~~~~~~~~~~~
In file included from postgres_stats.c:6:
/usr/include/postgresql/15/server/miscadmin.h:460:13: note: declared here
  460 | extern void InitPostgres(const char *in_dbname, Oid dboid,
      |             ^~~~~~~~~~~~
make: *** [<builtin>: postgres_stats.o] Error 1
CyberDem0n commented 1 year ago

Fixed in the master branch: https://github.com/CyberDem0n/bg_mon/commit/04fc15fdf81d9e66a9431eca868244c1aaf78b65