diff --git a/lib/wind/gen-bidi.py b/lib/wind/gen-bidi.py index 42af72f3b..70abb1ed7 100644 --- a/lib/wind/gen-bidi.py +++ b/lib/wind/gen-bidi.py @@ -70,6 +70,7 @@ extern const size_t _wind_l_table_size; bidi_c.file.write( ''' +#include #include "bidi_table.h" ''') diff --git a/lib/wind/gen-combining.py b/lib/wind/gen-combining.py index f7e9bf881..cc692fd2a 100644 --- a/lib/wind/gen-combining.py +++ b/lib/wind/gen-combining.py @@ -73,6 +73,7 @@ extern const size_t _wind_combining_table_size; combining_c.file.write( ''' +#include #include "combining_table.h" const struct translation _wind_combining_table[] = { diff --git a/lib/wind/gen-errorlist.py b/lib/wind/gen-errorlist.py index 6ea88d7bc..b921377ab 100644 --- a/lib/wind/gen-errorlist.py +++ b/lib/wind/gen-errorlist.py @@ -77,6 +77,7 @@ extern const size_t _wind_errorlist_table_size; errorlist_c.file.write( ''' +#include #include "errorlist_table.h" const struct error_entry _wind_errorlist_table[] = { diff --git a/lib/wind/gen-normalize.py b/lib/wind/gen-normalize.py index 0a20b71cf..c076088fd 100644 --- a/lib/wind/gen-normalize.py +++ b/lib/wind/gen-normalize.py @@ -97,6 +97,7 @@ extern const unsigned short _wind_canon_next_table[]; normalize_c.file.write( ''' +#include #include "normalize_table.h" const struct translation _wind_normalize_table[] = { diff --git a/lib/wind/gen-punycode-examples.py b/lib/wind/gen-punycode-examples.py index c22e011d0..44f5dafe5 100644 --- a/lib/wind/gen-punycode-examples.py +++ b/lib/wind/gen-punycode-examples.py @@ -104,6 +104,7 @@ extern const size_t punycode_examples_size; examples_c.file.write( ''' +#include #include "punycode_examples.h" const struct punycode_example punycode_examples[] = { diff --git a/lib/wind/libwind-exports.def b/lib/wind/libwind-exports.def new file mode 100644 index 000000000..66d6c946e --- /dev/null +++ b/lib/wind/libwind-exports.def @@ -0,0 +1,23 @@ +EXPORTS + wind_stringprep + wind_profile + wind_punycode_label_toascii + wind_utf8ucs4 + wind_utf8ucs4_length + wind_ucs4utf8 + wind_ucs4utf8_length + wind_ucs2utf8 + wind_utf8ucs2 + wind_utf8ucs2_length + wind_ucs2utf8_length + wind_ucs2read + +; testing + _wind_combining_class + _wind_stringprep_testbidi + _wind_stringprep_error + _wind_stringprep_prohibited + _wind_stringprep_map + _wind_stringprep_normalize + _wind_ldap_case_exact_attribute + _wind_ucs2read diff --git a/lib/wind/test-bidi.c b/lib/wind/test-bidi.c index d62f48a19..913747378 100644 --- a/lib/wind/test-bidi.c +++ b/lib/wind/test-bidi.c @@ -45,7 +45,7 @@ struct test { }; static struct test passing_cases[] = { - {0, {}}, + {0, {0}}, {1, {0x0041}}, {1, {0x05be}}, }; diff --git a/lib/wind/test-ldap.c b/lib/wind/test-ldap.c index 72a125d5f..7051a7fe8 100644 --- a/lib/wind/test-ldap.c +++ b/lib/wind/test-ldap.c @@ -50,7 +50,7 @@ struct testcase { }; static const struct testcase testcases[] = { - { { 0x20 }, 1, { }, 0 }, + { { 0x20 }, 1, { 0 }, 0 }, { { 0x20, 0x61 }, 2, { 0x20, 0x61, 0x20}, 3 }, { { 0x20, 0x61, 0x20 }, 3, { 0x20, 0x61, 0x20}, 3 }, { { 0x20, 0x61, 0x20, 0x61 }, 4, { 0x20, 0x61, 0x20, 0x20, 0x61, 0x20}, 6 } diff --git a/lib/wind/test-map.c b/lib/wind/test-map.c index 5b0f49381..fcc86007b 100644 --- a/lib/wind/test-map.c +++ b/lib/wind/test-map.c @@ -51,10 +51,10 @@ struct example { }; static struct example cases[] = { - {{}, 0, {}, 0}, + {{0}, 0, {0}, 0}, {{0x0041}, 1, {0x0061}, 1}, {{0x0061}, 1, {0x0061}, 1}, - {{0x00AD}, 1, {}, 0}, + {{0x00AD}, 1, {0}, 0}, {{0x00DF}, 1, {0x0073, 0x0073}, 2} }; @@ -95,3 +95,4 @@ main(void) failures += try(&cases[i]); return failures != 0; } + diff --git a/lib/wind/test-rw.c b/lib/wind/test-rw.c index 62f68e2f3..9e39d8540 100644 --- a/lib/wind/test-rw.c +++ b/lib/wind/test-rw.c @@ -67,7 +67,7 @@ struct testcase { WIND_RW_BOM, 2, "\xfe\xff", 0, - 0, { }, + 0, { 0 }, WIND_RW_BE }, /* no input */ @@ -75,7 +75,7 @@ struct testcase { WIND_RW_BOM, 0, "", 0, - 0, { }, + 0, { 0 }, WIND_RW_BOM }, /* BOM only */ @@ -83,7 +83,7 @@ struct testcase { WIND_RW_BOM, 2, "\xff\xfe", 0, - 0, { }, + 0, { 0 }, WIND_RW_LE }, /* water + z */ @@ -123,7 +123,7 @@ struct testcase { WIND_RW_BOM, 1, "\xfe", WIND_ERR_LENGTH_NOT_MOD2, - 0, { }, + 0, { 0 }, WIND_RW_BOM }, /* error, missing BOM */ @@ -131,7 +131,7 @@ struct testcase { WIND_RW_BOM, 2, "\x00\x20", WIND_ERR_NO_BOM, - 0, { }, + 0, { 0 }, WIND_RW_BOM }, /* error, overrun */ diff --git a/lib/wind/test-utf8.c b/lib/wind/test-utf8.c index 3197528b6..d85df286e 100644 --- a/lib/wind/test-utf8.c +++ b/lib/wind/test-utf8.c @@ -78,7 +78,7 @@ struct testcase { }; static const struct testcase testcases[] = { - {"", 0, {}}, + {"", 0, {0}}, {"\x01", 1, {1}}, {"\x7F", 1, {0x7F}}, {"\x01\x7F", 2, {0x01, 0x7F}}, diff --git a/lib/wind/windlocl.h b/lib/wind/windlocl.h index fb5e0b25d..da9d58cfe 100644 --- a/lib/wind/windlocl.h +++ b/lib/wind/windlocl.h @@ -41,6 +41,7 @@ #endif #include +#include #include "wind.h" #include "wind_err.h"