relibc: add LDBL_DIG, DECIMAL_DIG, LDBL_MIN/MAX_10_EXP to float.h cbindgen
C11 <float.h> requires these macros. Without them, gnulib-based packages (diffutils, coreutils, etc.) fail with 'LDBL_DIG undeclared'.
This commit is contained in:
@@ -42,6 +42,9 @@ after_includes = """
|
||||
|
||||
#define LDBL_HAS_SUBNORM 1
|
||||
#define LDBL_DECIMAL_DIG DECIMAL_DIG
|
||||
#define LDBL_DIG 18
|
||||
#define LDBL_MIN_10_EXP (-4931)
|
||||
#define LDBL_MAX_10_EXP 4932
|
||||
|
||||
// TODO: Support more architectures than x86_64 here:
|
||||
#define LDBL_TRUE_MIN 3.6451995318824746025e-4951L
|
||||
@@ -53,6 +56,8 @@ after_includes = """
|
||||
#define LDBL_MIN_EXP (-16381)
|
||||
#define LDBL_MAX_EXP 16384
|
||||
|
||||
#define DECIMAL_DIG 21
|
||||
|
||||
#endif // _RELIBC_BITS_FLOAT_H
|
||||
"""
|
||||
language = "C"
|
||||
|
||||
Reference in New Issue
Block a user