abseil-cpp: Set CMAKE_CXX_STANDARD to 17

The compiler defaults to C++ < 17 which causes build failures.
Abseil requires C++17 or higher, so explicitly set CMAKE_CXX_STANDARD=17
to ensure the build uses the correct C++ standard.

Error:
CMake Error at CMake/AbseilDll.cmake:745 (message):
  The compiler defaults to or is configured for C++ < 17.  C++ >= 17 is
  required and Abseil and all libraries that use Abseil must use the same C++
  language standard

Signed-off-by: Yogesh Tyagi <yogesh.tyagi@intel.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
This commit is contained in:
Yogesh Tyagi
2026-02-03 03:20:55 +08:00
committed by Khem Raj
parent 7c54c935cb
commit 0feab39283
@@ -21,6 +21,7 @@ inherit cmake
EXTRA_OECMAKE = "-DBUILD_SHARED_LIBS=ON \
-DBUILD_TESTING=OFF \
-DABSL_ENABLE_INSTALL=ON \
-DCMAKE_CXX_STANDARD=17 \
"
# riscv32-yoe-linux-ld.lld: error: undefined reference: __atomic_store_8
# >>> referenced by <recipe-sysroot>/usr/lib/libabsl_flags_internal.so.2505.0.0 (disallowed by --no-allow-shlib-undefined)