ibarwick / firebird_fdw

A PostgreSQL foreign data wrapper (FDW) for Firebird - latest version 1.4.0 (2024-05-11)
https://sql-info.de/postgresql/firebird-fdw/index.html
Other
36 stars 8 forks source link

1.2.0 build error #19

Closed devrimgunduz closed 4 years ago

devrimgunduz commented 4 years ago

Hi,

I'm getting the error below while compiling 1.2.0 on all Fedora releases. Can you please take a look? I can build packages fine on RHEL 7 and 8.

FWIW, Fedora 31 uses gcc 9.3, and Fedora 32 and 33 use gcc 10.

Thanks! Devrim

/usr/lib64/ccache/clang -Wno-ignored-attributes -fno-strict-aliasing -fwrapv -O2  -I/usr/include/firebird -I. -I./ -I/usr/pgsql-12/include/server -I/usr/pgsql-12/include/internal  -D_GNU_SOURCE -I/usr/include/libxml2  -I/usr/include -flto=thin -emit-llvm -c -o src/options.bc src/options.c
/usr/lib64/ccache/clang -Wno-ignored-attributes -fno-strict-aliasing -fwrapv -O2  -I/usr/include/firebird -I. -I./ -I/usr/pgsql-12/include/server -I/usr/pgsql-12/include/internal  -D_GNU_SOURCE -I/usr/include/libxml2  -I/usr/include -flto=thin -emit-llvm -c -o src/firebird_fdw.bc src/firebird_fdw.c
gcc -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Werror=vla -Wendif-labels -Wmissing-format-attribute -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard -Wno-format-truncation -Wno-stringop-truncation -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fPIC -shared -o firebird_fdw.so src/connection.o src/convert.o src/options.o src/firebird_fdw.o -L/usr/pgsql-12/lib   -L/usr/lib64  -L/usr/lib64 -Wl,--as-needed -Wl,-rpath,'/usr/pgsql-12/lib',--enable-new-dtags  -lfq -lfbclient 
/usr/bin/ld: src/convert.o:/home/devrim/Documents/Devrim/Projects/repo/pgrpms/rpm/redhat/master/non-common/firebird_fdw/main/firebird_fdw-1.2.0/src/firebird_fdw.h:70: multiple definition of `opttype'; src/connection.o:/home/devrim/Documents/Devrim/Projects/repo/pgrpms/rpm/redhat/master/non-common/firebird_fdw/main/firebird_fdw-1.2.0/src/firebird_fdw.h:70: first defined here
/usr/bin/ld: src/options.o:/home/devrim/Documents/Devrim/Projects/repo/pgrpms/rpm/redhat/master/non-common/firebird_fdw/main/firebird_fdw-1.2.0/src/firebird_fdw.h:70: multiple definition of `opttype'; src/connection.o:/home/devrim/Documents/Devrim/Projects/repo/pgrpms/rpm/redhat/master/non-common/firebird_fdw/main/firebird_fdw-1.2.0/src/firebird_fdw.h:70: first defined here
/usr/bin/ld: src/firebird_fdw.o:/home/devrim/Documents/Devrim/Projects/repo/pgrpms/rpm/redhat/master/non-common/firebird_fdw/main/firebird_fdw-1.2.0/src/firebird_fdw.h:70: multiple definition of `opttype'; src/connection.o:/home/devrim/Documents/Devrim/Projects/repo/pgrpms/rpm/redhat/master/non-common/firebird_fdw/main/firebird_fdw-1.2.0/src/firebird_fdw.h:70: first defined here
collect2: error: ld returned 1 exit status
ibarwick commented 4 years ago

Issue confirmed on Fedora 32 and fixed, thanks for the report!