Created attachment 1302205 [details] Patch to fix bugs in glog-0.3.3, which causes glog fail to build by GCC 7.1.1 in Fedora 26 Description of problem: glog-0.3.3-12.fc25.src.rpm failed to build in Fedora 26 How reproducible: Download glog-0.3.3-12.fc25.src.rpm from koji.fedoraproject.org build glog in Fedora 26 system with command rpmbuild --rebuild glog-0.3.3-12.fc25.src.rpm Actual results: Compiler reports: src/demangle.cc: In function 'bool google::AtLeastNumCharsRemaining(const char*, int)': src/demangle.cc:170:16: error: ISO C++ forbids comparison between pointer and integer [-fpermissive] if (str == '\0') { ^~~~ src/demangle.cc: In function 'bool google::ParseCharClass(google::State*, const char*)': src/demangle.cc:226:29: error: ISO C++ forbids comparison between pointer and integer [-fpermissive] if (state->mangled_cur == '\0') { ^~~~ Expected results: glog builds successfully Additional info: After I investigating on this issue, I found that this compiling error is caused by bugs str == '\0' should be changed to str[i] == '\0' state->mangled_cur == '\0' should be changed to state->mangled_cur[0] == '\0' I have created a patch to fix this issue. Patch is attached.
https://src.fedoraproject.org/rpms/glog/c/9a08f01de655bde757baf9943ba3dfc7a2b6c4ff?branch=master