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

fix(build): fix compilation error on MacOS for C++14 #1648

Merged
merged 3 commits into from
Oct 19, 2023

Conversation

empiredan
Copy link
Contributor

@empiredan empiredan commented Oct 19, 2023

#1647

The standard followed by v2.5
would be C++14. However, Compilation on MacOS failed due to some errors, such as:

  • no member named 'make_unique' in namespace 'std'
  • initialized lambda captures are a C++14 extension
  • 'ext/alloc_traits.h' file not found

Most of the errors are about C++14. cmake directives should be fixed to make C++14
compilation on MacOS work well.

@empiredan empiredan marked this pull request as draft October 19, 2023 03:26
@github-actions github-actions bot added the build label Oct 19, 2023
@github-actions github-actions bot added the cpp label Oct 19, 2023
@empiredan
Copy link
Contributor Author

#include <ext/alloc_traits.h> should be declared as no_include with IWYU due to following compilation error on MacOS:

[ 43%] Building CXX object src/meta/CMakeFiles/dsn_meta_server.dir/meta_service_app.cpp.o
/Users/runner/work/incubator-pegasus/incubator-pegasus/src/meta/meta_service.cpp:29:10: fatal error: 'ext/alloc_traits.h' file not found
#include <ext/alloc_traits.h>
         ^~~~~~~~~~~~~~~~~~~~
1 error generated.
make[2]: *** [src/meta/CMakeFiles/dsn_meta_server.dir/meta_service.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....

@empiredan empiredan added cmake 2.5 issues and pull requests dedicated to v2.5 labels Oct 19, 2023
@empiredan empiredan changed the title fix(build): fix compilation error on MacOS due to C++14 fix(build): fix compilation error on MacOS for C++14 Oct 19, 2023
@empiredan empiredan marked this pull request as ready for review October 19, 2023 07:26
@empiredan empiredan merged commit c9bf449 into apache:v2.5 Oct 19, 2023
75 checks passed
@empiredan empiredan mentioned this pull request Dec 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2.5 issues and pull requests dedicated to v2.5 build cmake cpp
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants