[Bug 1787619] Review Request: tucnak - VHF contest logging program

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



https://bugzilla.redhat.com/show_bug.cgi?id=1787619



--- Comment #7 from Robert-André Mauchin <zebob.m@xxxxxxxxx> ---
(In reply to Robert-André Mauchin from comment #6)
>  - Build still fails after all this:
> 
> /usr/bin/ld: menu2.o:(.bss+0xa20): multiple definition of `operator_';
> menu1.o:(.bss+0x3f88): first defined here
> /usr/bin/ld: rotar.o:(.bss+0x18): multiple definition of `hdkeyb';
> hdkeyb.o:(.bss+0x0): first defined here
> /usr/bin/ld: sked.o:/builddir/build/BUILD/tucnak-4.18/src/sked.c:28:
> multiple definition of `remark';
> menu2.o:/builddir/build/BUILD/tucnak-4.18/src/menu2.c:66: first defined here
> /usr/bin/ld: sked.o:/builddir/build/BUILD/tucnak-4.18/src/sked.c:27:
> multiple definition of `callsign';
> menu2.o:/builddir/build/BUILD/tucnak-4.18/src/menu2.c:62: first defined here
> /usr/bin/ld: sked.o:/builddir/build/BUILD/tucnak-4.18/src/sked.c:27:
> multiple definition of `locator';
> menu2.o:/builddir/build/BUILD/tucnak-4.18/src/menu2.c:62: first defined here
> /usr/bin/ld: sked.o:/builddir/build/BUILD/tucnak-4.18/src/sked.c:28:
> multiple definition of `time_str';
> menu2.o:/builddir/build/BUILD/tucnak-4.18/src/menu2.c:66: first defined here
> collect2: error: ld returned 1 exit status
> make[2]: *** [Makefile:538: tucnak] Error 1

This is related to this change in GCC 10:

GCC now defaults to -fno-common. As a result, global variable accesses are more
efficient on various targets. In C, global variables with multiple tentative
definitions now result in linker errors. With -fcommon such definitions are
silently merged during linking. 

https://gcc.gnu.org/gcc-10/changes.html

Default to -fno-common

A common mistake in C is omitting extern when declaring a global variable in a
header file. If the header is included by several files it results in multiple
definitions of the same variable. In previous GCC versions this error is
ignored. GCC 10 defaults to -fno-common, which means a linker error will now be
reported. To fix this, use extern in header files when declaring global
variables, and ensure each global is defined in exactly one C file. As a
workaround, legacy C code can be compiled with -fcommon.


      int x;  // tentative definition - avoid in header files

      extern int y;  // correct declaration in a header file

https://gcc.gnu.org/gcc-10/porting_to.html


Please contact upstream for them to port their code to GCC 10.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
You are always notified about changes to this product and component
_______________________________________________
package-review mailing list -- package-review@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to package-review-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/package-review@xxxxxxxxxxxxxxxxxxxxxxx




[Index of Archives]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite Conditions]     [KDE Users]

  Powered by Linux