Skip to content

Commit

Permalink
libplugin: fix compilation issue on recent gccs.
Browse files Browse the repository at this point in the history
They now use -fno-common by default, so duplicated variables cause
a link error:

/usr/bin/ld: common/utils.o:(.bss+0x10): multiple definition of `chainparams'; plugins/libplugin.o:(.bss+0x0): first defined here
collect2: error: ld returned 1 exit status
make: *** [Makefile:408: plugins/autoclean] Error 1

This was introduced in 9ebfdf0.

Fixes: #3597
Signed-off-by: Rusty Russell <[email protected]>
Changelog-Fixed: Multiple definition of chainparams on Fedora (or other really recent gcc)
  • Loading branch information
rustyrussell committed Apr 7, 2020
1 parent 11c21f9 commit d9084f7
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions plugins/libplugin.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@

#define READ_CHUNKSIZE 4096

const struct chainparams *chainparams;

bool deprecated_apis;

struct plugin_timer {
Expand Down

0 comments on commit d9084f7

Please sign in to comment.