[Slony1-bugs] Slony build failure with GCC 10

Moradhassel, Kavian kmoradha at ciena.com
Thu May 21 17:28:00 UTC 2020


Hello,

GCC 10 has changed its default from “-fcommon” to “-fno-common” (ref<https://gcc.gnu.org/legacy-ml/gcc-patches/2019-10/msg01847.html>), and this results in build failure following several errors such as:

/usr/bin/ld: runtime_config.o:/tmp/slony1-2.2.8/src/slon/confoptions.h:46: multiple definition of `Syslog_ident'; slon.o:/tmp/slony1-2.2.8/src/slon/confoptions.h:46: first defined here
/usr/bin/ld: local_listen.o:/tmp/slony1-2.2.8/src/slon/confoptions.h:56: multiple definition of `command_on_logarchive'; slon.o:/tmp/slony1-2.2.8/src/slon/confoptions.h:56: first defined here
/usr/bin/ld: remote_listen.o:/tmp/slony1-2.2.8/src/slon/confoptions.h:53: multiple definition of `log_timestamp_format'; slon.o:/tmp/slony1-2.2.8/src/slon/confoptions.h:53: first defined here
/usr/bin/ld: remote_worker.o:/tmp/slony1-2.2.8/src/slon/confoptions.h:54: multiple definition of `sql_on_connection'; slon.o:/tmp/slony1-2.2.8/src/slon/confoptions.h:54: first defined here
/usr/bin/ld: sync_thread.o:/tmp/slony1-2.2.8/src/slon/confoptions.h:55: multiple definition of `lag_interval'; slon.o:/tmp/slony1-2.2.8/src/slon/confoptions.h:55: first defined here
/usr/bin/ld: monitor_thread.o:/tmp/slony1-2.2.8/src/slon/confoptions.h:52: multiple definition of `drop_indices'; slon.o:/tmp/slony1-2.2.8/src/slon/confoptions.h:52: first defined here

The above is just a sample of the error messages…several dozen of these actually occur, and then the build fails with:

collect2: error: ld returned 1 exit status

This change in default value is referenced as the first item on the “Porting to GCC 10” page, along with a description of how best to address this change:
https://gcc.gnu.org/gcc-10/porting_to.html

The workaround is to set CFLAGS="-fcommon" when running the configure script.  However, a more permanent fix would be appreciated.

Thanks,

Kav Moradhassel
R&D Tools and Services<https://confluence.ciena.com/display/prism> | Ciena
5050 Innovation Drive<https://cienacorp.sharepoint.com/sites/RealEstate/SitePages/Ottawa-Ontario.aspx>, Ottawa, ON, K2K 0J2, Canada

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.slony.info/pipermail/slony1-bugs/attachments/20200521/cbc53abc/attachment.htm>


More information about the Slony1-bugs mailing list