cmake: compile with -std=gnu++1z by default
Summary: Switch from `-std=gnu++14` to `-std=gnu++1z` This is required in order to allow downstream projects that use folly to build with `-std=gnu++1z`. The linkage for how constexpr variables are emitted has changed between `gnu++14` and `gnu++1z`. If folly is compiled with `gnu++14` but downstream dependencies try to build with `gnu++1z` they will get link errors (multiple definitions) for constexpr variables defined in folly header files. The reverse (compiling folly with `gnu++1z` but downstream projects with `gnu++14`) does not seem to cause any problems. Nonetheless, I have provided `CXX_STD` as a CMake option so that users can override this setting if it does cause any problems for some reason. Reviewed By: yfeldblum Differential Revision: D10448691 fbshipit-source-id: c44f568a7ff175c432865badeaaa9b3ebbaf8987
Showing
Please register or sign in to comment