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

Build fails for C++23 and Libstdc++, missing std::unexpected_handler #2322

Open
christianbrugger opened this issue Oct 20, 2024 · 0 comments

Comments

@christianbrugger
Copy link

christianbrugger commented Oct 20, 2024

Folly fails to build with c++23 due to the use of std::unexpectedHandler. It seems to be removed by Libstdc++.

[212/328] Building CXX object folly/CMakeFiles/folly_base.dir/folly/lang/Exception.cpp.o
FAILED: folly/CMakeFiles/folly_base.dir/folly/lang/Exception.cpp.o 
/usr/bin/g++-13 -DBOOST_ATOMIC_DYN_LINK -DBOOST_ATOMIC_NO_LIB -DBOOST_CONTEXT_DYN_LINK 
-DBOOST_CONTEXT_NO_LIB -DBOOST_FILESYSTEM_DYN_LINK -DBOOST_FILESYSTEM_NO_LIB 
-DBOOST_PROGRAM_OPTIONS_DYN_LINK -DBOOST_PROGRAM_OPTIONS_NO_LIB -DBOOST_REGEX_DYN_LINK 
-DBOOST_REGEX_NO_LIB -DBOOST_SYSTEM_DYN_LINK -DBOOST_SYSTEM_NO_LIB -DBOOST_THREAD_DYN_LINK 
-DBOOST_THREAD_NO_LIB -DFMT_SHARED -DFOLLY_XLOG_STRIP_PREFIXES=
\"/home/chris/folly_debug:/home/chris/folly_debug/build/linux-gcc-debug\" -DGFLAGS_IS_A_DLL=0 
-D_GNU_SOURCE -D_REENTRANT -I/home/chris/folly_debug/folly -I/home/chris/folly_debug/build/
linux-gcc-debug/folly -g -g -Wall -Wextra -std=c++23 -fcoroutines -g -finput-charset=UTF-8 
-fsigned-char -Wall -Wno-deprecated -Wno-deprecated-declarations -Wno-sign-compare 
-Wno-unused -Wuninitialized -Wunused-label -Wunused-result -Wshadow-compatible-local 
-Wno-noexcept-type -faligned-new -fopenmp -MD -MT 
folly/CMakeFiles/folly_base.dir/folly/lang/Exception.cpp.o 
-MF folly/CMakeFiles/folly_base.dir/folly/lang/Exception.cpp.o.d 
-o folly/CMakeFiles/folly_base.dir/folly/lang/Exception.cpp.o 
-c /home/chris/folly_debug/folly/folly/lang/Exception.cpp

/home/chris/folly_debug/folly/folly/lang/Exception.cpp:107:8: 
                                error: ‘unexpected_handler’ in namespace ‘std’ does not name a type
  107 |   std::unexpected_handler unexpectedHandler;
      |        ^~~~~~~~~~~~~~~~~~
[221/328] Building CXX object folly/CMakeFiles/folly_base.dir/folly/json/JSONSchema.cpp.o

I tested this on Ubuntu 24.04 with GCC 13.2.0.

@christianbrugger christianbrugger changed the title Build fails for C++23 and Libstdc++, removed std::unexpected_handler Build fails for C++23 and Libstdc++, missing std::unexpected_handler Oct 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant