mirror of
https://github.com/odin-lang/Odin.git
synced 2026-04-18 20:40:28 +00:00
fix(android): pass --sysroot when compiling the android glue code
This prevents a `function-like macro '__GLIBC_USE' is not defined` compilation error from happening with newer NDK versions (I tried r28)
This commit is contained in:
@@ -655,6 +655,11 @@ try_cross_linking:;
|
||||
glue = gb_string_append_length(glue, android_glue_object.text, android_glue_object.len);
|
||||
glue = gb_string_appendc(glue, "\" ");
|
||||
|
||||
glue = gb_string_appendc(glue, "--sysroot \"");
|
||||
glue = gb_string_append_length(glue, ODIN_ANDROID_NDK_TOOLCHAIN.text, ODIN_ANDROID_NDK_TOOLCHAIN.len);
|
||||
glue = gb_string_appendc(glue, "sysroot");
|
||||
glue = gb_string_appendc(glue, "\" ");
|
||||
|
||||
glue = gb_string_appendc(glue, "\"-I");
|
||||
glue = gb_string_append_length(glue, ODIN_ANDROID_NDK_TOOLCHAIN.text, ODIN_ANDROID_NDK_TOOLCHAIN.len);
|
||||
glue = gb_string_appendc(glue, "sysroot/usr/include/");
|
||||
|
||||
Reference in New Issue
Block a user