# see absl/debugging/internal/examine_stack.cc for the list of
# architectures that are supported, and for which ucontext is used.
config BR2_PACKAGE_LIBABSEIL_CPP_ARCH_SUPPORTS
	bool
	default y if BR2_aarch64 || BR2_aarch64_be
	default y if BR2_arm || BR2_armeb
	default y if BR2_i386
	default y if BR2_mips || BR2_mipsel || BR2_mips64 || BR2_mips64el
	default y if BR2_powerpc || BR2_powerpc64 || BR2_powerpc64le
	default y if BR2_riscv
	default y if BR2_x86_64
	depends on BR2_TOOLCHAIN_HAS_UCONTEXT

config BR2_PACKAGE_LIBABSEIL_CPP
	bool "libabseil-cpp"
	depends on BR2_INSTALL_LIBSTDCPP
	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
	depends on BR2_TOOLCHAIN_HAS_THREADS
	depends on !BR2_STATIC_LIBS # uses dlfcn.h
	depends on BR2_PACKAGE_LIBABSEIL_CPP_ARCH_SUPPORTS
	help
	  Abseil is an open-source collection of C++ library code
	  designed to augment the C++ standard library. The Abseil
	  library code is collected from Google's own C++ code base,
	  has been extensively tested and used in production, and is
	  the same code we depend on in our daily coding lives.

	  https://github.com/abseil/abseil-cpp

comment "libabseil-cpp needs a toolchain w/ gcc >= 4.9, C++, threads, dynamic library"
	depends on BR2_PACKAGE_LIBABSEIL_CPP_ARCH_SUPPORTS
	depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS || \
		BR2_STATIC_LIBS || !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
