build: add support for Android NDK path configuration

This commit is contained in:
Elias Andualem
2026-02-21 18:07:03 +08:00
parent 2a81d8cd29
commit bd9611650f
10 changed files with 219 additions and 0 deletions

View File

@@ -62,6 +62,10 @@ pub fn initShared(
.{ .include_extensions = &.{".h"} },
);
if (lib.rootModuleTarget().abi.isAndroid()) {
try @import("android_ndk").addPaths(b, lib);
}
if (lib.rootModuleTarget().os.tag.isDarwin()) {
// Self-hosted x86_64 doesn't work for darwin. It may not work
// for other platforms too but definitely darwin.