Bug 2171864 - re2 is polluting C++ compiler flags with -std=c++11
Summary: re2 is polluting C++ compiler flags with -std=c++11
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: re2
Version: 37
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Denis Arnaud
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 2171845 2171846
TreeView+ depends on / blocked
 
Reported: 2023-02-20 16:16 UTC by Vitaly
Modified: 2023-02-24 04:45 UTC (History)
3 users (show)

Fixed In Version: re2-20220601-1.fc36 re2-20220601-1.fc37
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-02-24 03:46:18 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Vitaly 2023-02-20 16:16:19 UTC
Description of problem:
re2 is polluting C++ compiler flags with -std=c++11 and breaks other projects in dependency tree:
Cflags: -std=c++11 -pthread -I${includedir}

Please patch manually or update the re package to version 20220601-1. It was fixed by upstream, I guess:
Cflags: -pthread -I${includedir}

Version-Release number of selected component (if applicable):
re2-20211101-3.fc36

How reproducible:
Always.

Steps to Reproduce:
1. Run build of any dependent package, requires modern C++, for example mtxclient.
2. -std=c++11 flag will be added and compilation terminated.
3.

Actual results:
[1/76] /usr/bin/g++ -DFMT_LOCALE -DFMT_SHARED -DJSON_DIAGNOSTICS=0 -DJSON_USE_IMPLICIT_CONVERSIONS=1 -DSPDLOG_COMPILED_LIB -DSPDLOG_FMT_EXTERNAL -DSPDLOG_SHARED_LIB -Dmatrix_client_EXPORTS -I/builddir/build/BUILD/mtxclient-0.9.2/include -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection 		-Wall 		-Wextra 		-Wconversion 		-pipe 		-pedantic 		-fsized-deallocation 		-fdiagnostics-color=always 		-Wno-attributes 		-Wunreachable-code -DNDEBUG -std=c++20 -fPIC -std=c++11 -pthread -DSPDLOG_SHARED_LIB -DSPDLOG_COMPILED_LIB -DSPDLOG_FMT_EXTERNAL -MD -MT CMakeFiles/matrix_client.dir/lib/crypto/encoding.cpp.o -MF CMakeFiles/matrix_client.dir/lib/crypto/encoding.cpp.o.d -o CMakeFiles/matrix_client.dir/lib/crypto/encoding.cpp.o -c /builddir/build/BUILD/mtxclient-0.9.2/lib/crypto/encoding.cpp

Expected results:
[1/76] /usr/bin/g++ -DFMT_SHARED -DSPDLOG_COMPILED_LIB -DSPDLOG_FMT_EXTERNAL -DSPDLOG_SHARED_LIB -Dmatrix_client_EXPORTS -I/builddir/build/BUILD/mtxclient-0.9.2/include -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64  -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer 		-Wall 		-Wextra 		-Wconversion 		-pipe 		-pedantic 		-fsized-deallocation 		-fdiagnostics-color=always 		-Wno-attributes 		-Wunreachable-code -DNDEBUG -std=c++20 -fPIC -pthread -DSPDLOG_SHARED_LIB -DSPDLOG_COMPILED_LIB -DSPDLOG_FMT_EXTERNAL -MD -MT CMakeFiles/matrix_client.dir/lib/crypto/encoding.cpp.o -MF CMakeFiles/matrix_client.dir/lib/crypto/encoding.cpp.o.d -o CMakeFiles/matrix_client.dir/lib/crypto/encoding.cpp.o -c /builddir/build/BUILD/mtxclient-0.9.2/lib/crypto/encoding.cpp

Additional info:

Comment 2 Denis Arnaud 2023-02-20 16:28:36 UTC
Thanks for reporting the issue!

I'll work on it when I have some time (during my free time over the weekends, usually).
In the meantime, do not hesitate to submit a pull request (https://src.fedoraproject.org/rpms/re2).

Comment 3 Vitaly 2023-02-20 16:35:34 UTC
PR with fix: https://src.fedoraproject.org/rpms/re2/pull-request/4

Please merge it and build for F37 and F36.

Comment 4 Vitaly 2023-02-21 13:14:49 UTC
Can you build it for F36 and F37? It blocks my packages from being updated.

Comment 5 Denis Arnaud 2023-02-21 14:15:14 UTC
(In reply to Vitaly Zaitsev from comment #4)
> Can you build it for F36 and F37? It blocks my packages from being updated.

Yes, I will try to do it tonight (CEST time-zone).

Comment 6 Fedora Update System 2023-02-22 10:51:10 UTC
FEDORA-2023-0895e66cc6 has been submitted as an update to Fedora 37. https://bodhi.fedoraproject.org/updates/FEDORA-2023-0895e66cc6

Comment 7 Fedora Update System 2023-02-22 10:51:56 UTC
FEDORA-2023-56a007f603 has been submitted as an update to Fedora 36. https://bodhi.fedoraproject.org/updates/FEDORA-2023-56a007f603

Comment 8 Fedora Update System 2023-02-23 01:59:57 UTC
FEDORA-2023-56a007f603 has been pushed to the Fedora 36 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2023-56a007f603`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2023-56a007f603

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 9 Fedora Update System 2023-02-23 03:02:19 UTC
FEDORA-2023-0895e66cc6 has been pushed to the Fedora 37 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2023-0895e66cc6`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2023-0895e66cc6

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 10 Fedora Update System 2023-02-24 03:46:18 UTC
FEDORA-2023-56a007f603 has been pushed to the Fedora 36 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 11 Fedora Update System 2023-02-24 04:45:21 UTC
FEDORA-2023-0895e66cc6 has been pushed to the Fedora 37 stable repository.
If problem still persists, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.