Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 909446 - kde-plasma/plasma-vault-5.27.6 fails to compile (lto): kded/engine/backends/cryfs/cryfsbackend.cpp:33:12: error: type ‘PlasmaVault::ExitCode’ violates the C++ One Definition Rule [-Werror=odr]
Summary: kde-plasma/plasma-vault-5.27.6 fails to compile (lto): kded/engine/backends/c...
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Gentoo KDE team
Depends on:
Blocks: lto
  Show dependency tree
Reported: 2023-07-01 15:31 UTC by Kostadin Shishmanov
Modified: 2023-07-01 15:42 UTC (History)
0 users

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

build log (build.log,125.35 KB, text/x-log)
2023-07-01 15:31 UTC, Kostadin Shishmanov

Note You need to log in before you can comment on or make changes to this bug.
Description Kostadin Shishmanov 2023-07-01 15:31:24 UTC
Created attachment 864975 [details]
build log

kde-plasma/plasma-vault-5.27.6 fails to compile with -flto -Werror=odr added to CFLAGS and CXXFLAGS

/var/tmp/portage/kde-plasma/plasma-vault-5.27.6/work/plasma-vault-5.27.6/kded/engine/backends/cryfs/cryfsbackend.cpp:33:12: error: type ‘PlasmaVault::ExitCode’ violates the C++ One Definition Rule [-Werror=odr]
   33 | enum class ExitCode : int {
      |            ^
/var/tmp/portage/kde-plasma/plasma-vault-5.27.6/work/plasma-vault-5.27.6/kded/engine/backends/gocryptfs/gocryptfsbackend.cpp:32:12: note: an enum with different value name is defined in another translation unit
   32 | enum class ExitCode : int {
      |            ^
/var/tmp/portage/kde-plasma/plasma-vault-5.27.6/work/plasma-vault-5.27.6/kded/engine/backends/cryfs/cryfsbackend.cpp:37:5: note: name ‘UnspecifiedError’ differs from name ‘NonEmptyCipherDir’ defined in another translation unit
   37 |     UnspecifiedError = 1,
      |     ^
/var/tmp/portage/kde-plasma/plasma-vault-5.27.6/work/plasma-vault-5.27.6/kded/engine/backends/gocryptfs/gocryptfsbackend.cpp:36:5: note: mismatching definition
   36 |     NonEmptyCipherDir = 6,
      |     ^
lto1: some warnings being treated as errors
lto-wrapper: fatal error: /usr/bin/x86_64-pc-linux-gnu-g++ returned 1 exit status
compilation terminated.
/usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: error: lto-wrapper failed
collect2: error: ld returned 1 exit status
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-07-01 15:32:13 UTC
We really need to see if we can remove cryfs entirely really, as the new versions are hard to package (conan..).