New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Building fails in Fedora 32 #40
Comments
Hi @Baggypants, Thanks for the report. I'd be curious to know the version of gcc in Fedora 32 and the Python scripts building tty-solitaire. It looks like it's trying to somehow link duplicate object files? For example, for the "cursor" object, if we look at this line output:
There are both And
Do you have a Fedora setup and would be able to debug it? |
[baggypants@buildserver ~]$ rpm -qa gcc
gcc-10.0.1-0.13.fc32.x86_64 The python stuff is just the automated build system and doesn't impact on the build. Heres the HEAD build on a classic make-in-a-directory machine [baggypants@buildserver tty-solitaire]$ make
cc -g -W -Wall -pedantic -ansi -std=c99 -DVERSION=\"1.1.1\" src/ttysolitaire.c -o ttysolitaire src/common.o src/frame.o src/card.o src/stack.o src/deck.o src/cursor.o src/keyboard.o src/gui.o src/game.o -lncursesw
/usr/bin/ld: src/cursor.o:(.bss+0x0): multiple definition of `deck'; /tmp/cce1xEvH.o:(.bss+0x0): first defined here
/usr/bin/ld: src/cursor.o:/home/baggypants/Develop/tty-solitaire/src/game.h:38: multiple definition of `cursor'; /tmp/cce1xEvH.o:/home/baggypants/Develop/tty-solitaire/src/game.h:38: first defined here
/usr/bin/ld: src/keyboard.o:(.bss+0x0): multiple definition of `deck'; /tmp/cce1xEvH.o:(.bss+0x0): first defined here
/usr/bin/ld: src/keyboard.o:(.bss+0x8): multiple definition of `cursor'; /tmp/cce1xEvH.o:/home/baggypants/Develop/tty-solitaire/src/game.h:38: first defined here
/usr/bin/ld: src/gui.o:(.bss+0x0): multiple definition of `deck'; /tmp/cce1xEvH.o:(.bss+0x0): first defined here
/usr/bin/ld: src/gui.o:/home/baggypants/Develop/tty-solitaire/src/game.h:38: multiple definition of `cursor'; /tmp/cce1xEvH.o:/home/baggypants/Develop/tty-solitaire/src/game.h:38: first defined here
/usr/bin/ld: src/game.o:(.bss+0x0): multiple definition of `deck'; /tmp/cce1xEvH.o:(.bss+0x0): first defined here
/usr/bin/ld: src/game.o:/home/baggypants/Develop/tty-solitaire/src/game.h:38: multiple definition of `cursor'; /tmp/cce1xEvH.o:/home/baggypants/Develop/tty-solitaire/src/game.h:38: first defined here
collect2: error: ld returned 1 exit status
make: *** [Makefile:48: ttysolitaire] Error 1
[baggypants@buildserver tty-solitaire]$ |
Similar error on Arch. Downgrading gcc and gcc-libs to 9.3.0-1 produces no errors. Current version is 10.1.0-2.
|
@dther thanks for the report. Are you able to investigate? Unfortunately I don't currently have access to a Fedora or Arch environment. |
A gcc-10 changes the default behaviour from -fcommon to -fno-common, which causes linking errors in some build processes. Fixes mpereira#40.
@Baggypants v1.3.0 was released with a fix for this. Thanks again for reporting! |
linker seems to not like something when compiling in f32. Extract of build output below.
This is from the v1.1.1 tag but the same occurs on the building of HEAD.
The text was updated successfully, but these errors were encountered: