Skip to content

[GLUTEN-10162] [build] fix: GCC build fix #10161

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

Closed
wants to merge 2 commits into from
Closed

Conversation

NN---
Copy link

@NN--- NN--- commented Jul 10, 2025

What changes were proposed in this pull request?

Clang 18 fails building.

How was this patch tested?

Building using clang 18.

Copy link

Thanks for opening a pull request!

Could you open an issue for this pull request on Github Issues?

https://github.com/apache/incubator-gluten/issues

Then could you also rename commit message and pull request title in the following format?

[GLUTEN-${ISSUES_ID}][COMPONENT]feat/fix: ${detailed message}

See also:

@NN--- NN--- changed the title Fix build for clang 18 [GLUTEN-10162] [build] fix: Clang 18 build fix Jul 10, 2025
Copy link

#10162

@zhouyuan
Copy link
Contributor

Cc @zml1206 as he is also fixing macos builds

@@ -101,7 +101,7 @@ function compile {
# Maybe there is some set option in velox setup script. Run set command again.
set -exu

CXX_FLAGS='-Wno-error=stringop-overflow -Wno-error=cpp -Wno-missing-field-initializers -Wno-unknown-warning-option'
CXX_FLAGS='-Wno-error=stringop-overflow -Wno-error=cpp -Wno-missing-field-initializers -Wno-unknown-warning-option -Wno-template-id-cdtor'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

-Wno-template-id-cdtor seems to be gcc specific, not supported by clang.

clang-18 -Wno-template-id-cdtor a.cpp
warning: unknown warning option '-Wno-template-id-cdtor' [-Wunknown-warning-option]

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for confusion. Yes it is for GCC.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What version of gcc? Could you post the relevant error? Thanks

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

GCC 14

Copy link
Contributor

@zml1206 zml1206 Jul 16, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems to be caused by C++20. Docker uses gcc11 and C++17 to compile, so this problem will not occur. You can use gcc11 or specify -std=c++17 to see if the problem can be solved. cc @zhouyuan @rui-mo

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see. Thanks. I am moving gluten build to a separate environment.

@NN--- NN--- changed the title [GLUTEN-10162] [build] fix: Clang 18 build fix [GLUTEN-10162] [build] fix: GCC build fix Jul 11, 2025
@NN--- NN--- closed this Jul 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants