Bug 1923339

Summary: thermald: FTBFS in Fedora rawhide/f34
Product: [Fedora] Fedora Reporter: Fedora Release Engineering <releng>
Component: thermaldAssignee: Benjamin Berg <bberg>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 34CC: bberg, besser82, ckellner, law, msebor, msebor
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-02-13 21:35:23 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1868278    
Attachments:
Description Flags
build.log
none
root.log
none
state.log none

Description Fedora Release Engineering 2021-02-01 16:37:09 UTC
thermald failed to build from source in Fedora rawhide/f34

https://koji.fedoraproject.org/koji/taskinfo?taskID=60906802


For details on the mass rebuild see:

https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
Please fix thermald at your earliest convenience and set the bug's status to
ASSIGNED when you start fixing it. If the bug remains in NEW state for 8 weeks,
thermald will be orphaned. Before branching of Fedora 35,
thermald will be retired, if it still fails to build.

For more details on the FTBFS policy, please visit:
https://docs.fedoraproject.org/en-US/fesco/Fails_to_build_from_source_Fails_to_install/

Comment 1 Fedora Release Engineering 2021-02-01 16:37:12 UTC
Created attachment 1753064 [details]
build.log

file build.log too big, will only attach last 32768 bytes

Comment 2 Fedora Release Engineering 2021-02-01 16:37:13 UTC
Created attachment 1753065 [details]
root.log

file root.log too big, will only attach last 32768 bytes

Comment 3 Fedora Release Engineering 2021-02-01 16:37:15 UTC
Created attachment 1753066 [details]
state.log

Comment 4 Benjamin Berg 2021-02-02 14:08:11 UTC
As I see it, it is choking on a static c string assignment to an std:string. i.e. the code does:

modem_path.assign("/ril_0");

where modem_path is defined as "std::string modem_path;" inside "class cthd_cdev_modem".

Comment 5 Ben Cotton 2021-02-09 15:47:55 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 34 development cycle.
Changing version to 34.

Comment 6 Martin Sebor 2021-02-09 18:51:21 UTC
Same as in bug 1909564, the warning below (copied from https://kojipkgs.fedoraproject.org//work/tasks/1800/60911800/build.log) is due to upstream GCC bug https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98465.

In file included from /usr/include/c++/11/ios:40,
                 from /usr/include/c++/11/istream:38,
                 from /usr/include/c++/11/fstream:38,
                 from src/thd_sys_fs.h:33,
                 from src/thd_cdev.h:31,
                 from src/thd_cdev_modem.h:22,
                 from src/thd_cdev_modem.cpp:29:
In function 'std::char_traits<char>::copy(char*, char const*, unsigned int)',
    inlined from 'std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::_S_copy(char*, char const*, unsigned int)' at /usr/include/c++/11/bits/basic_string.h:351:21,
    inlined from 'std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::_S_copy(char*, char const*, unsigned int)' at /usr/include/c++/11/bits/basic_string.h:346:7,
    inlined from 'std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::_M_replace(unsigned int, unsigned int, char const*, unsigned int)' at /usr/include/c++/11/bits/basic_string.tcc:481:20,
    inlined from 'std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::assign(char const*)' at /usr/include/c++/11/bits/basic_string.h:1445:19,
    inlined from 'cthd_cdev_modem::cthd_cdev_modem(unsigned int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >)' at src/thd_cdev_modem.cpp:129:29:
/usr/include/c++/11/bits/char_traits.h:402:56: error: 'memcpy' reading 6 bytes from a region of size 1 [-Werror=stringop-overread]
  402 |         return static_cast<char_type*>(__builtin_memcpy(__s1, __s2, __n));
      |                                        ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
cc1plus: all warnings being treated as errors

Comment 7 Jeff Law 2021-02-13 21:35:23 UTC
Fixed after latest compiler update.