Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compile errors occur when using gcc 14 #2591

Open
kpvdr opened this issue Mar 14, 2024 · 9 comments
Open

Compile errors occur when using gcc 14 #2591

kpvdr opened this issue Mar 14, 2024 · 9 comments
Assignees
Labels
bug Something isn't working needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one.

Comments

@kpvdr
Copy link

kpvdr commented Mar 14, 2024

When building opentelemetry-cpp 1.14.2 for Fedora using gcc-c++ 14.0.1 (which is the default for upcoming Fedora 40 and rawhide), compile errors occur. Builds for the current Fedora 38 and 39 which use gcc-c++ 13.2.1 succeed.

The errors appear to concern templates and their argument lists. The builds may be seen on Copr[1] with the build logs and environments. All the failed builds are using gcc 14.0.1. When I built 1.13.0 a few months back, Fedora 40 and rawhide were still using gcc 1.13.2, and they were successful. All the build failures for Fedora 40 and rawhide appear to be identical.

Because Copr deletes the build logs for failed builds after a few days, I have attached the log for the x86_64 rawhide build.
builder-live.log.gz

[1] https://copr.fedorainfracloud.org/coprs/kpvdr/opentelemetry-cpp/build/7153160/

@kpvdr kpvdr added the bug Something isn't working label Mar 14, 2024
@github-actions github-actions bot added the needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. label Mar 14, 2024
@owent
Copy link
Member

owent commented Mar 16, 2024

GCC 14 is not released yet. I will test and fix all the compatibility problem after GCC 14 is released.

@marcalff marcalff added triage/accepted Indicates an issue or PR is ready to be actively worked on. and removed needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Mar 26, 2024
@kpvdr
Copy link
Author

kpvdr commented May 1, 2024

It appears that 14 is not yet officially released on gnu.org. However, Fedora 40 has been released and uses gcc 14.0.1.

@kpvdr
Copy link
Author

kpvdr commented May 8, 2024

gcc 14.1 was relesaed on May 7. (https://gcc.gnu.org/gcc-14)

@owent
Copy link
Member

owent commented May 9, 2024

Thanks, I will test it several days later.

@marcalff marcalff self-assigned this May 16, 2024
@marcalff
Copy link
Member

Can not reproduce.

The opentelemetry-cpp CI was upgraded to use gcc-14, and it passes without code changes:

Please reopen with details if this is still an issue.

@owent
Copy link
Member

owent commented Jun 7, 2024

I built otel-cpp v1.15.0 with GCC 14 successfully without any modification. But I found other problems with GCC 14 when building other packages. I solved the compiling problems by add -Wno-error=incompatible-pointer-types and -Wno-error=implicit-int to CFLAGS and CXXFLAGS. Hope helpful for your situation.

@kpvdr
Copy link
Author

kpvdr commented Jun 24, 2024

This issue appears to occur when the internal abseil code is used. A cmake build which does not set WITH_ABSEIL or setting WITH_ABSEIL=OFF will cause the internal abseil code to be used. Building with this configuration using GCC14 appears to trigger the issue.

@kpvdr
Copy link
Author

kpvdr commented Jun 24, 2024

This issue is still present on 1.16.0.

@marcalff marcalff reopened this Nov 28, 2024
@github-actions github-actions bot added the needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. label Nov 28, 2024
@marcalff marcalff removed the triage/accepted Indicates an issue or PR is ready to be actively worked on. label Nov 28, 2024
@owent
Copy link
Member

owent commented Dec 2, 2024

This issue appears to occur when the internal abseil code is used. A cmake build which does not set WITH_ABSEIL or setting WITH_ABSEIL=OFF will cause the internal abseil code to be used. Building with this configuration using GCC14 appears to trigger the issue.

This problem should already be fixed in #3041 . Could you please have a test?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one.
Projects
None yet
Development

No branches or pull requests

3 participants