Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 776571 - sys-apps/roccat-tools-5.9.0-r100: fails to build with gcc 10 (multiple definition of `RyosWriteCheckWait'; ryosmk/libroccatryosmk/CMakeFiles/libroccatryosmk.dir/ryos_custom_lights.c.o:(.bss+0x0): first defined here)
Summary: sys-apps/roccat-tools-5.9.0-r100: fails to build with gcc 10 (multiple defini...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Lars Wendler (Polynomial-C) (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: -fno-common
  Show dependency tree
 
Reported: 2021-03-15 21:14 UTC by Acatorn
Modified: 2021-08-13 23:24 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build log (build.log,780.45 KB, text/x-log)
2021-03-15 21:14 UTC, Acatorn
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Acatorn 2021-03-15 21:14:51 UTC
Created attachment 691632 [details]
build log

Hello,
I performed regular system upgrade at 13.03.2021. During that event gcc got upgraded to 10.2.0 so I attempted to rebuild all packages twice (according to https://wiki.gentoo.org/wiki/Upgrading_GCC) using below commands:

emerge --ask --emptytree --usepkg=n @system (everything finished successfully)
emerge --ask --emptytree --usepkg=n @world

During the rebuild of @world sys-apps/roccat-tools-5.9.0-r100 failed to build with below output:

collect2: error: ld returned 1 exit status
ninja: build stopped: subcommand failed.
 * ERROR: sys-apps/roccat-tools-5.9.0-r100::gentoo failed (compile phase):
 *   ninja -v -j1 -l0 failed
 *
 * Call stack:
 *     ebuild.sh, line  125:  Called src_compile
 *   environment, line 3037:  Called cmake_src_compile
 *   environment, line  981:  Called cmake_build
 *   environment, line  950:  Called eninja
 *   environment, line 1714:  Called die
 * The specific snippet of code:
 *       "$@" || die "${nonfatal_args[@]}" "${*} failed"
 *
 * If you need support, post the output of `emerge --info '=sys-apps/roccat-tools-5.9.0-r100::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=sys-apps/roccat-tools-5.9.0-r100::gentoo'`.
 * The complete build log is located at '/var/log/portage/sys-apps:roccat-tools-5.9.0-r100:20210315-204440.log'.
 * For convenience, a symlink to the build log is located at '/var/tmp/portage/sys-apps/roccat-tools-5.9.0-r100/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/sys-apps/roccat-tools-5.9.0-r100/temp/environment'.
 * Working directory: '/var/tmp/portage/sys-apps/roccat-tools-5.9.0-r100/work/roccat-tools-5.9.0_build'
 * S: '/var/tmp/portage/sys-apps/roccat-tools-5.9.0-r100/work/roccat-tools-5.9.0'

>>> Failed to emerge sys-apps/roccat-tools-5.9.0-r100, Log file:

>>>  '/var/log/portage/sys-apps:roccat-tools-5.9.0-r100:20210315-204440.log'


Full /var/tmp/portage/sys-apps/roccat-tools-5.9.0-r100/temp/build.log in attachement.
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-03-15 21:24:44 UTC
As a workaround, you can use CFLAGS="... -fcommon" for this package
Comment 2 Acatorn 2021-03-15 21:38:27 UTC
(In reply to Sam James from comment #1)
> As a workaround, you can use CFLAGS="... -fcommon" for this package

Thank you, Sam. Running:

CFLAGS="${COMMON_FLAGS} -fcommon" emerge -av sys-apps/roccat-tools

worked like a charm.

Many thanks for your fast reply!
Comment 3 Acatorn 2021-06-14 00:04:46 UTC
Recently I upgraded gcc from 10.2.0 to 10.3.0 and that problem still exists.

Is there any way to make it great again without that workaround?
Is it an upstream incompatibility with gcc > 9 or something else?
Can I help in any way?
Comment 4 Ayron 2021-08-06 10:39:10 UTC
The problem comes from an unused declaration of RyosWriteCheckWait in ryosmk/libroccatryosmk/ryos_device.h. This patch solves the bug:

--- a/ryosmk/libroccatryosmk/ryos_device.h      2021-08-06 10:14:03.928000000 +0000
+++ b/ryosmk/libroccatryosmk/ryos_device.h      2021-08-06 10:18:29.536000000 +0000
@@ -22,10 +22,6 @@
 
 G_BEGIN_DECLS
 
-enum {
-       RYOS_WRITE_CHECK_WAIT_LIGHT_CONTROL = 10,
-} RyosWriteCheckWait;
-
 /*
  * write selection: (before profile specific read)
  *   value = profile index 0-4
Comment 5 Larry the Git Cow gentoo-dev 2021-08-13 23:24:09 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=dea923aa48ca7c97492b24780c374a0181cb5273

commit dea923aa48ca7c97492b24780c374a0181cb5273
Author:     David Seifert <soap@gentoo.org>
AuthorDate: 2021-08-13 23:24:01 +0000
Commit:     David Seifert <soap@gentoo.org>
CommitDate: 2021-08-13 23:24:01 +0000

    sys-apps/roccat-tools: fix -fno-common / GCC 10
    
    Closes: https://bugs.gentoo.org/776571
    Signed-off-by: David Seifert <soap@gentoo.org>

 .../roccat-tools/files/roccat-tools-5.9.0-fno-common.patch    | 11 +++++++++++
 sys-apps/roccat-tools/roccat-tools-5.9.0-r101.ebuild          |  1 +
 2 files changed, 12 insertions(+)