Add `HAVE_STDBOOL_H` define for Alberta when `stdbool.h` is available
2 unresolved threads
Compare changes
Files
2+ 13
− 0
@@ -109,8 +109,21 @@ find_package_handle_standard_args("Alberta"
In older versions of Alberta, it tries to fix the issues around not having
proper bool in C by redefining bool as _Bool. Clang's stdbool header
defines _Bool as bool, which then leads to a typedef bool bool
and that gives a
compile error. This whole bool/_Bool logic is inside an ifdef in
Alberta that is only active if HAVE_STDBOOL_H
is not defined.
If HAVE_STDBOOL_H
is defined, however, it just includes stdbool.h
and uses that. So we can check during
CMake configuration if stdbool.h
is available and set the flag accordingly.