Skip to content

Commit c9a6f4c

Browse files
committed
[tools] Add check for invalid ANDROID_NDK_ROOT
1 parent 0b59d98 commit c9a6f4c

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

tools/hxcpp/Setup.hx

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -434,6 +434,14 @@ class Setup
434434
else
435435
{
436436
root = defines.get("ANDROID_NDK_ROOT");
437+
438+
if (!FileSystem.exists(root)) {
439+
Log.error('ANDROID_NDK_ROOT ["$root"] directory does not exist');
440+
}
441+
if (!FileSystem.isDirectory(root)) {
442+
Log.error('ANDROID_NDK_ROOT ["$root"] is not a diretory');
443+
}
444+
437445
Log.setup("\x1b[33;1mUsing Android NDK root: " + root + "\x1b[0m");
438446
}
439447

0 commit comments

Comments
 (0)