Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 912853 - media-sound/clementine-1.4.0_rc2-r2 fails to compile (GLIBC-2.38-SYSTEM): policy_checks.h:79:2: error: #error "C++ versions less than C++14 are not supported."
Summary: media-sound/clementine-1.4.0_rc2-r2 fails to compile (GLIBC-2.38-SYSTEM): pol...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Alexey
URL: https://github.com/clementine-player/...
Whiteboard:
Keywords:
Depends on:
Blocks: 912819
  Show dependency tree
 
Reported: 2023-08-23 06:38 UTC by Agostino Sarubbo
Modified: 2023-12-08 03:04 UTC (History)
7 users (show)

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


Attachments
build.log (build.log,569.16 KB, text/plain)
2023-08-23 06:38 UTC, Agostino Sarubbo
Details
clementine fix for protobuf (99_clementine_gcc_std_c++17.patch,2.90 KB, patch)
2023-08-30 09:03 UTC, Max Steel
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Agostino Sarubbo gentoo-dev 2023-08-23 06:38:03 UTC
https://blogs.gentoo.org/ago/2020/07/04/gentoo-tinderbox/

Issue: media-sound/clementine-1.4.0_rc2-r2 fails to compile (GLIBC-2.38-SYSTEM).
Discovered on: amd64 (internal ref: glibc2.38_tinderbox)

NOTE:
(GLIBC-2.38-SYSTEM) in the summary means that the bug was found on a machine that runs glibc-2.38 but this bug MAY or MAY NOT BE related to the new libc version
Comment 1 Agostino Sarubbo gentoo-dev 2023-08-23 06:38:05 UTC
Created attachment 868512 [details]
build.log

build log and emerge --info
Comment 2 Agostino Sarubbo gentoo-dev 2023-08-23 06:38:06 UTC
Error(s) that match a know pattern in addition to what has been reported in the summary:


FAILED: ext/libclementine-remote/CMakeFiles/libclementine-remote.dir/remotecontrolmessages.pb.cc.o 
FAILED: ext/libclementine-tagreader/CMakeFiles/libclementine-tagreader.dir/gmereader.cpp.o 
FAILED: ext/libclementine-tagreader/CMakeFiles/libclementine-tagreader.dir/tagreader.cpp.o 
FAILED: ext/libclementine-tagreader/CMakeFiles/libclementine-tagreader.dir/tagreadermessages.pb.cc.o 
--   Package 'libcdio', required by 'virtual:world', not found
--   Package 'libgpod-1.0', required by 'virtual:world', not found
--   Package 'libmtp', required by 'virtual:world', not found
--   Package 'libpulse', required by 'virtual:world', not found
--   Package 'libspotify', required by 'virtual:world', not found
/var/tmp/portage/media-sound/clementine-1.4.0_rc2-r2/work/Clementine-1.4.0rc2/3rdparty/qsqlite/qsql_sqlite.cpp:106:37: warning: ‘QSqlError::QSqlError(const QString&, const QString&, ErrorType, int)’ is deprecated [-Wdeprecated-declarations]
/var/tmp/portage/media-sound/clementine-1.4.0_rc2-r2/work/Clementine-1.4.0rc2/3rdparty/qsqlite/qsql_sqlite.cpp: In function ‘QSqlError qMakeError(sqlite3*, const QString&, QSqlError::ErrorType, int)’:
/usr/include/absl/base/policy_checks.h:79:2: error: #error "C++ versions less than C++14 are not supported."
Comment 3 Max Steel 2023-08-29 20:13:30 UTC
For this compilation Problem there exists a current Upstream Bug:
https://github.com/clementine-player/Clementine/issues/7272
Comment 4 Max Steel 2023-08-30 08:57:26 UTC
The mentioned patch fixes the C++14 Errors, but another error for undefined symbols in abseil-cpp is also mentioned and not yet fixed.

Regardless i attach the patch here, for your convenience.
Comment 5 Max Steel 2023-08-30 09:03:23 UTC
Created attachment 869035 [details, diff]
clementine fix for protobuf

Not yet fully working fix for C++14 Compatibility

Still errors during linking:
> [1150/1176] : && /usr/bin/x86_64-pc-linux-gnu-g++ -march=native -O2 -pipe -Wl,-O1 -Wl,--as-needed    -rdynamic ext/clementine-tagreader/CMakeFiles/clementine-tagreader.dir/main.cpp.o ext/clementine-tagreader/CMakeFiles/clementine-tagreader.dir/tagreaderworker.cpp.o ext/clementine-tagreader/CMakeFiles/clementine-tagreader.dir/qrc_data.cpp.o -o clementine-tagreader  -ltag  -lz  ext/libclementine-common/liblibclementine-common.a  ext/libclementine-tagreader/liblibclementine-tagreader.a  -lz  ext/libclementine-common/liblibclementine-common.a  -ltag  -lz  /usr/lib64/libQt5Network.so.5.15.10  /usr/lib64/libQt5Core.so.5.15.10  -lprotobuf && :
> FAILED: clementine-tagreader 
> /usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: ext/libclementine-tagreader/liblibclementine-tagreader.a(tagreadermessages.pb.cc.o): undefined reference to symbol '_ZN4absl12lts_2023080212log_internal17MakeCheckOpStringIllEEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEET_T0_PKc'
> /usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../x86_64-pc-linux-gnu/bin/ld: /usr/lib/gcc/x86_64-pc-linux-gnu/13/../../../../lib64/libabsl_log_internal_check_op.so.2308.0.0: error adding symbols: DSO missing from command line
> collect2: error: ld returned 1 exit status


On current abseil-cpp Version the referenced Symbol does indeed not exist. But there exists an similar Symbol with a slightly different version.
> # strings /usr/lib64/libabsl_log_internal_check_op.so.2308.0.0 | grep _ZN4absl12lts_2023012512log_internal21CheckOpMessageBuilder7ForVar2Ev
> # strings /usr/lib64/libabsl_log_internal_check_op.so.2308.0.0 | grep _ZN4absl12lts | grep internal21CheckOpMessageBuilder7ForVar2Ev
> _ZN4absl12lts_2023080212log_internal21CheckOpMessageBuilder7ForVar2Ev
Comment 6 Max Steel 2023-08-30 10:55:59 UTC
Downgrading abseil-cpp to 20230125.3-r1 and protobuf to 21.12 does work

Steps to reproduce
1. # cat >> /etc/portage/package.accept_keywords/zzzz << EOF
>=dev-libs/protobuf-23.3 -~amd64
>=dev-cpp/abseil-cpp-20230802 -~amd64
EOF
2. # emerge -uDN @world
3. # emerge @preserved-rebuilds
Comment 7 Alexey 2023-09-28 07:24:09 UTC
Adding "absl_log_internal_check_op absl_log_internal_message" to `target_link_libraries(libclementine-tagreader` fixes the build, however, it indicates that either protobuf or abseil-cpp forgot to declare some dependency in their exported cmake configs
Comment 8 Larry the Git Cow gentoo-dev 2023-10-17 05:24:15 UTC
The bug has been referenced in the following commit(s):

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

commit a19cfd05bb1bc1ed9ed84342a95bca123b347eb9
Author:     Alexey Sokolov <alexey+gentoo@asokolov.org>
AuthorDate: 2023-10-06 17:56:47 +0000
Commit:     Yixun Lan <dlan@gentoo.org>
CommitDate: 2023-10-17 05:23:48 +0000

    media-sound/clementine: Fix build with new abseil and proto
    
    Bug: https://bugs.gentoo.org/912853
    Bug: https://bugs.gentoo.org/913738
    Signed-off-by: Alexey Sokolov <alexey+gentoo@asokolov.org>
    Signed-off-by: Yixun Lan <dlan@gentoo.org>

 .../clementine/clementine-1.4.0_rc2-r4.ebuild      | 168 +++++++++++++++++++++
 media-sound/clementine/clementine-9999.ebuild      |   6 +
 .../files/clementine-1.4.0_rc2-absl.patch          |  15 ++
 .../files/clementine-1.4.0_rc2-c17.patch           |  67 ++++++++
 4 files changed, 256 insertions(+)
Comment 9 Andrés Becerra Sandoval 2023-10-24 12:31:05 UTC
This is solved with the commit referenced above. Should it be closed?
Comment 10 Alexey 2023-10-24 19:06:06 UTC
I sometimes randomly delay closing until the fixed package is stabilized and the bad version is removed, but yeah, can close it already...
Comment 11 Fat-Zer 2023-12-08 03:04:22 UTC
Note that the clementine-1.4.0_rc2-absl.patch causes a build failure when linking against older dev-cpp/abseil-cpp: see bug 919422.