Skip to content

Fix builf on -fno-common toolchains#104

Open
trofi wants to merge 1 commit intoxorg62:masterfrom
trofi:fix-gcc-10-build
Open

Fix builf on -fno-common toolchains#104
trofi wants to merge 1 commit intoxorg62:masterfrom
trofi:fix-gcc-10-build

Conversation

@trofi
Copy link
Copy Markdown

@trofi trofi commented May 6, 2022

gcc-10 changed the default from -fcommon to fno-common:
https://gcc.gnu.org/PR85678

As a result build fails as:

ld: src/log.o:(.bss+0x0): multiple definition of `W'; src/barwin.o:(.bss+0x0): first defined here
ld: src/wmfs.o:(.bss+0x0): multiple definition of `W'; src/barwin.o:(.bss+0x0): first defined here
ld: src/wmfs.o:(.bss+0x10): multiple definition of `event_handle'; src/client.o:(.bss+0x10): first defined here

The change moves definitions into .c files.

gcc-10 changed the default from -fcommon to fno-common:
  https://gcc.gnu.org/PR85678

As a result build fails as:

    ld: src/log.o:(.bss+0x0): multiple definition of `W'; src/barwin.o:(.bss+0x0): first defined here
    ld: src/wmfs.o:(.bss+0x0): multiple definition of `W'; src/barwin.o:(.bss+0x0): first defined here
    ld: src/wmfs.o:(.bss+0x10): multiple definition of `event_handle'; src/client.o:(.bss+0x10): first defined here

The change moves definitions into .c files.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant